0.1.9 • Published 4 years ago

system-invoke-html-webpack-plugin v0.1.9

Weekly downloads
2
License
MIT
Repository
github
Last release
4 years ago

system-invoke-html-webpack-plugin

Inject System.import() into HtmlWebpackPlugin template.

Install

npm i -D system-invoke-html-webpack-plugin

Usage

webpack.config.js

...
plugins: [
  new HtmlWebpackPlugin(),
  new SystemHtmlWebpackPlugin()
  ...
]

html

<html>
<body>
...
<!-- systemjs lib need to be imported by your self or use 'include-assets-html-webpack-plugin' -->
<script src="/assets/js/systemjs.js"></script>
<script src="/assets/js/vendors.chunk.js"></script>
<script src="/assets/js/main.js"></script>
<!-- system-invoke-html-webpack-plugin just do this use System to import the last js -->
<script type="text/javascript">System.import("/assets/js/main.js");</script>
</body>
</html>

API

new SystemHtmlWebpackPlugin(name)   // default is the last js that append to body

License

MIT

0.1.9

4 years ago

0.1.8

4 years ago

0.1.7

4 years ago

0.1.6

4 years ago

0.1.5

4 years ago

0.1.4

4 years ago

0.1.3

4 years ago