Yeoman generator for Nitro - lets you quickly set up a frontend project with sensible defaults and best practices.
Nitro is a Node.js application for simple and complex frontend development with a tiny footprint.
It provides a proven but flexible structure to develop your frontend code, even in a large team.
Keep track of your code with a modularized frontend. This app and the suggested
atomic design and BEM
concepts could help.
Nitro is simple, fast and flexible. It works on macOS, Windows and Linux. Use this app for all your frontend work.
Before using, you need of course node installed.
Nitro and the Nitro generator are tested with the current
"Active LTS" versions of node.js (release 6.x and 8.x).
Install yarn
, yo
and generator-nitro
globally:
npm install -g yarn yo generator-nitro
Keep your global packages up to date:
npm outdated -g --depth=0
Do an update if necessary:
npm update -g
Create a new directory, and cd
into it:
mkdir my-new-project && cd my-new-project
Run:
yo nitro
You will be guided through some configuration options:
- Desired Name
--name=
(default: current directory name) - Desired CSS preprocessor
--pre=
(less
orscss
; default:scss
) - Desired view file extension
--viewExt=
(html
,hbs
ormustache
; default:hbs
) - Using client side templates
--clientTpl
(default: false) - Including example code
--exampleCode
(default: false) - Installing
nitro-exporter
--exporter
(default: false) - Installing
nitro-release
--release
(default: false)
The choosen options will be stored for the next project generation.
It's possible to pass in these options through the command line:
yo nitro --name=myproject --pre=less --viewExt=hbs --clientTpl
You may bypass the questions with --skip-questions
. This will use the defaults for not specified options
yo nitro --name=myproject --clientTpl --exporter --skip-questions
In your project, first update the generator to the newest version:
yarn add generator-nitro
If you then run yo nitro
you will be asked to update the project.
It is best to overwrite all local files and check the differences after.
Updating to a new major version needs some more work. Please check the release notes
Available generators:
yo nitro
(akayo nitro:app
)yo nitro:pattern [name]
Note: Generators are to be run from the root directory of your project.
See how to use the generated app
Running yarn test
will run the jasmine
unit tests.
yarn test
We are more than happy to accept external contributions to the project in the form of feedback, bug reports and pull requests :)
See the contributing docs
Recent changes can be viewed on Github on the Releases Page