Compiling
Browser side
The front-end bundle is builded by webpack. When using the cli command to create a project, it will be automatically generated webpack config
We used awesome-typescript-loader as ts loader, and has config babel, add babel-polyfill
to bundle. it will support ie9+.
The entry of webpack is view/app.tsx
in the project by default.
|
|
Run webpack build
to build the default project, it will generate a bundle of size at about 400K. Dependent library composition as shown below:
The default webpack.config.js
has four IgnorePlugin plugins, because some files are required at both front and server side, so we need to ignore the server-side requires.
|
|