Html-webpack-tag-path-fix
Fix the problem of static files when the
'publicpath'
is a relative path on the deep level page;
The plugin depends on 'HTML webpack plugin' ^ 3.2.0 '
Problems solved:
When a multi page application is a deep level page, for example, in the following case, when 'publicpath' is not an absolute address (relative path), the page will not find a static resource.
··· { /* omitted long function */ } chunks: 'chunk-vendors' 'chunk-common' 'index/list' template: 'myapp/src/page/index/list/list.html' filename: 'index/list.html' ···
Use
const htmlWebpackTagPathFix = // In the webpack configuration···plugins: ···
additional
Support injection Code: injectCode
injectCode: String || Function
Default delivery string injection to <div id=app></div>
Inside;
To customize; just pass onefunction
accept html
And return html