This is a Yeoman Generator for the Components of the Aurelia platform. It sets up a standard navigation-style app using gulp to build your ES6 code with Babel. Karma/Jasmine testing is configured as well.
For more info please visit the official site: http://www.aurelia.io/
This generator will use JSPM, Aurelias package manager of choice, which performs GitHub queries to install semver packages, but GitHub has a rate limit on anonymous API requests. It is advised that you configure jspm with your GitHub credentials in order to avoid problems. You can do this by executing jspm registry config github
and following the prompts. If you choose to authorize jspm by an access token instead of giving your password (see GitHub Settings > Personal Access Tokens), public_repo
access for the token is required.
The recent update will take care of running
npm install
andjspm install
after downloading the boilerplate app, so this shortens the process to get up and running.
- Verify that Yeoman is installed
npm install -g yo
- Install this generator
npm install -g generator-aurelia-base
- Inside your project execute
yo aurelia-base:view YOURPAGENAME
OR
yo aurelia-base:component YOURCOMPONENTNAME
OR
yo aurelia-base:example YOURCOMPONENTEXAMPLENAME
If you don't want tests to be generated for your component, add the notest
flag
yo aurelia-base:component YOURCOMPONENTNAME --notest
- Example
The following command will generate 3 files (namely
datepicker.html
,datepicker.js
anddatepicker.spec.js
) insrc/_components/picker
:
yo aurelia-base:component picker/datepicker