dynamic routing and common chunk for preact
search
damujiangr:
for details
related: damujiangr/react-router-dynamic-optimize
- command:
npm start // start app
npm run build // build and analysis
-
preact + preact-compat
Fast 3kB alternative to React with the same modern API.
-
preact-router
Connect your Preact components up to that address bar.
Note: This is not a preact-compatible version of React Router.
-
preact-async-route
Lazy loading (code splitting) with preact-router can be implemented easily using the AsyncRoute module.
-
history
Manage session history with JavaScript.
-
bundle analysis, plugins: webpack-bundle-analyzer
// damujiangr: require
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
// damujiangr: bundle analyer
new BundleAnalyzerPlugin(),