/dev

No-bundle dev server

Primary LanguageJavaScript

PoC of no-bundle dev server

Features in development environment:

  • No bundle: source files are processed on demand, one by one
  • Lazy loaded components with their own styles
  • CSS Modules together with CSS Modules Scripts
  • Server Side Rendering
  • Watch mode (TBD)

Running Dev Server

$ npm install
$ npm run dev
$ open https://localhost/

Notes

  • Dependencies from node_modules are resolved with import maps. It works natively in Chrome and using ES Module Shims in other browsers.

  • CSS files are loaded and attached using CSS Modules Scripts. Again it works in Chrome and uses Constructible style sheets polyfill in other browsers.

  • Keys and Certificate for the local https server are generated with devcert during the first launch.

  • Define HOST and PORT environment variables if you want to change the address of the development server.