Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6648157
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T00:37:19+00:00 2026-05-26T00:37:19+00:00

I am new to Coffeescript and I wonder where I should put them. Eg.

  • 0

I am new to Coffeescript and I wonder where I should put them.

Eg. I have my app folder:

app/app.js
tests/unit/all.js
etc

When I use the “coffee” runner on node.js to watch my files in the root folder it will generate js files to a folder I specify eg. js.

So if the folder to be watched is looking like this:

app/app.coffee
tests/unit/all.coffee
etc

JS files will be generated to:

js/app.js
js/all.js
etc

As you can see I lose my js folder hierarchy.

How are you supposed to retain your original folder hierarchy?

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T00:37:19+00:00Added an answer on May 26, 2026 at 12:37 am

    I believe you want

    coffee -cwo js .
    

    That will compile app/foo.coffee to js/app/foo.js, and test/bar.coffee to js/test/bar.js.

    As long as you stick to passing folder names to the coffee command, rather than individual file names, directory structure will be preserved.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Rails app, learning CoffeeScript and Backbone.js: Uncaught TypeError: Cannot use 'in' operator to search
I'm putting together a new app and, while I normally use JQuery for things
I'm new to Coffeescript, and I have a question about Ajax. jQuery -> api
I get the following error when I have coffeescript files in my assets/javascript folder
The coffeescript compiler is, for some reason, wrapping all of my .coffee files in
I am very new to coffeescript, and I have been trying to find a
I'm new to the world of coffeescript (javascript). Currently building my first backbone.js app
I'm new to javascript and starting the mix javascript + jquery + coffeescript all
I am quite new to vim and I am trying to edit coffeescript. Whenever
How do I instantiate a class in CoffeeScript when I only have the name

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.