Build Step
Koala Framework now has a build/compile/generate step.
This got merged into master recently and will be part of verison 3.8.
Why?
With the build step we can use external tools we don't want to depend on on production locally:
- libsass (for much faster (10x) sass to css compilation
- uglifyjs (for proper minification of javascript assets)
- sourcemaps generation (for sass, minified javascript and concated css & js)
Additionally we don't have to rebuild assets on every clear-cache on production servers which caused a downtime of (depending on the server) several minutes.
And one important point is performance - we now can rely on the existence of build files on production and don't have to lazy generate caches.
What?
Currently part of the build are:
- asset packages (compiled, minified, concated assets)
- trl (parsed trl.xml files ready for usage in Kwf_Trl, for improved performance)
- component settings (all static component settings)
- component events (event listeners aggregated from all components)
Dependencies
For a successful build several libraries node packages are required:
- node-sass (for compiling scss)
- uglifyjs (for minifying js)
- grunt-modernizr (for creating modernizr build)
Deployment to production
The idea behind the build is that you can share the generated files across servers. You should not build on production server, instead the locally build files should be copied to the production server.
Build Server
Creating a build Server is relatively easy as you just have download all dependencies and start the build. No database or local config required.
Github Activity
nsams commented on pull request koala-framework/kwc-newsletter#5
nsams commented on issue koala-framework/koala-framework#736
nsams starred ionic-team/stencil
A simple, reusable web component compiler
TypeScript 2.3k 5 issues need help Updated Feb 19
nsams commented on pull request koala-framework/koala-framework#728
nsams commented on pull request koala-framework/kwc-newsletter#2
Leave a Reply
Your email address will not be published.