I have used CoffeeScript for a while. Now I need to write a npm package, can I write it in CoffeeScript, or I should compile CoffeeScript into JavaScript?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
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.
I’m going to suggest that you write your package in coffeescript, but only publish it in javascript. I do it like this:
srclibsrcis committed to my git repo,libis in my.gitignorelibis published to npm,srcis in my.npmignorecoffee-scriptpackage is in mydevDependenciesYou can take a look at a simple package of mine, refix, for inspiration:
npm install refix