npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

eflex-ember-cli-coffeescript

v2.0.6

Published

Adds precompilation of CoffeeScript files and all the basic generation types to the `ember generate` command.

Downloads

12

Readme

CoffeeScript support for ember-cli Build Status

Adds precompilation of CoffeeScript files and all the basic generation types to the ember generate command, as well as linting.

Includes

  • Generating files in CoffeeScript with ember generate
  • Preprocessing CoffeeScript-files in your app, including tests
  • Linting your CoffeeScript-files.

Install

ember install ember-cli-coffeescript

NB: ember-cli-coffeescript is tested using ember-cli version 2.3.0 and up. Some of it probably works on earlier versions, but I wouldn't know.

How to use

Blueprints

Run ember help generate to get a list of available blueprints. Use them by running ember g <blueprint> <args>. For instance, to generate a component:

ember g component my-component

ember-cli-coffeescript comes with pod-support for the same blueprints as ember-cli does. Check out the ember-cli docs for pods for instructions on how to use it.

If you'd like to use ember-cli-coffeescript without the blueprints, you can add the following to your config/environment.js:

ENV.coffeeOptions = {
  blueprints: false
}

This will make it fall back to the next blueprints in line (probably the ones from ember-cli).

Precompiling

This will happen automatically - no work necessary.

Linting

If you have a coffeelint.json file in the root of you project we will automatically pick up on it and start running linting on files when using the ember build and ember serve commands. If you do not want linting to run despite having a coffeelint.json file, use the following configuration in your config/environment.js.

ENV.coffeeOptions = {
  lint: false
}

You can set lint to true to enable linting with the default configurations even without a custom coffeelint.json file.

You can find all the available options on the website for coffeelint.

If you want to specify a different path for your coffeelint.json file you can specify the path (relative to the project directory or absolute)

ENV.coffeeOptions = {
  lint: {
    configPath: "configurations/coffeelint.json"
  }
}

If you want to change the way we format the linting output you can specify custom error output and stats output functions:

ENV.coffeeOptions = {
  lint: {
    formatter: function(filePath, lintResults) {  },
    statsFormatter: function(stats) { console.log('Files: ', stats.fileCount, "Errors: ", stats.errorCount) }
  }
}

NOTE: The lint results will show up twice when you build and run your app; once for the app files, and then once for the test files. On rebuild, only the changed files are linted.

Lintignore

To avoid linting specific files or folders, you can put a file named .coffeelintignore in the root of your project containing ignore-rules, one per line. This is just like a .gitignore-file, and it will follow the same rules.

Developing

  • git clone this repository
  • npm install
  • bower install
  • npm link

Because of the nature of this project, it needs to be consumed by an ember-cli project to be properly developed.

  • Add "ember-cli-coffeescript": "*" to your consuming project's package.json
  • From your project root run npm link ember-cli-coffeescript

Running Tests

  • ember test
  • npm run embertest
  • npm run nodetest

To run all the tests:

  • npm test