Dojo Boilerplate: A Starter Kit for Dojo Development
The Dojo Boilerplate is a set of files to help you rapidly get up and running with the Dojo Toolkit. It illustrates some basic best practices when working with Dojo.
- Make sure you have Node.js and a Java runtime installed.
- Clone the repository using
git clone --recursive.
npm installto install additional Node.js dependencies.
- Develop your project in
src/until it is amazing.
build.sh, which will create an awesome optimised build in
dist/for millions of people the world over to enjoy.
If you have msysgit installed, run Git Bash and verify some dependencies by running the following commands:
which java which node
A brief tour
- All of the application's source goes in
src. It will be built into
- Build profiles for the build system go in
- The entrypoint of the demo application is the HTML file at
build.shscript takes your application files and builds them for production use using Stylus and the Dojo build system. It depends on the presence of an application build profile at
- The file
src/app/resources/app.stylcontains all the CSS for the application.
- Tests using Intern exist in the
testsdirectory. They can be run with
tests/run.sh. The test configuration is at
tests/intern.jsand defaults to using a Sauce Labs tunnel.
About the boilerplate
This boilerplate is occasionally updated to try to reflect the latest and greatest features and design patterns for writing Web apps with Dojo, but it relies heavily on information and contributions from other users. If you have an idea, suggestion, or problem, please report it or create a pull request! (Please note that you will need to have signed the Dojo CLA before your pull requests are accepted, for the good of us all!)
The Dojo Boilerplate is licensed under the New BSD license.