/millimetr-babel

⚡️ A millimetr starting template with Babel integration

Primary LanguageHTML

⚡️ millimetr-babel

This is a millimetr starting template with Babel integration

Note that Babel only does transpilation. If you want module resolution, i.e. via import/require then use millimetr-parcel or millimetr-webpack).

Note that the CSS selectors in this demo follow the BEM convention. However you are welcome to restructure them according to your preferences.

Getting started

  1. git clone https://github.com/millimetr/millimetr-babel.git
  2. npm install
  3. npm start

Principles

  • 📄 HTML templates are written in EJS
  • 🤖 The millimetr.config.js file is central to this starter.
  • 👓 No hidden behaviour, everything is documented via millimetr.config.js file.
  • All JavaScript files in the src/js folder will be transpiled (keeping the same file name) into src/static/assets

Example routes

This starting template starts with three routes:

  • /: The basic landing-route.
  • /hardcoded: Illustrates how hardcoded values can be passed to route templates.
  • /dynamic: Illustrates how dynamically generated values can be passed to route templates.
  • /remote: Illustrates how remote data can be fetched and passed to route templates.