Elixir
Elixir is automatically configured to handle the following:
- Pull in your main bower files from
bower.json
and generate thevendor.js
&vendor.css
. - Lint your files using eslint, generate sourcemaps, annotate your dependencies & concatenate everything into
app.js
(with EcmaScript 6 support, of course.) - Compile less and generate the
app.css
- Partials are automatically generated and injected using ngHtml2Js (gives a performance boost as it eliminates tons of network roundabouts)
- Live-reload
Always append
--save
to yourbower install
commands so that they can be found by the elixir bower plugin.
Overriding bower main files
Some packages do not have the correct or desired main
files definition in their bower.json
.
This where you have to use main-bower-files' overrides feature.
For example, here's what you can add to your bower.json in order to require bootstrap's css:
"overrides": {
"bootstrap": {
"main": [
"dist/css/bootstrap.css",
"dist/js/bootstrap.js"
]
}
}
ESLint errors/warnings
ESLint errors that you see in the terminal won't stop your code from running. They're only meant for code quality.
Disabling eslint on watch
You can disable eslint from running on watch by modifying the
tasks/angular.task.js
file
You can create custom elixir tasks inside
tasks/
Updated less than a minute ago