nav tabs on admin dashboard
This commit is contained in:
48
node_modules/html-loader/README.md
generated
vendored
48
node_modules/html-loader/README.md
generated
vendored
@@ -27,6 +27,20 @@ By default every local `<img src="image.png">` is required (`require('./image.pn
|
||||
|
||||
You can specify which tag-attribute combination should be processed by this loader via the query parameter `attrs`. Pass an array or a space-separated list of `<tag>:<attribute>` combinations. (Default: `attrs=img:src`)
|
||||
|
||||
If you use `<custom-elements>`, and lots of them make use of a `custom-src` attribute, you don't have to specify each combination `<tag>:<attribute>`: just specify an empty tag like `attrs=:custom-src` and it will match every element.
|
||||
|
||||
```js
|
||||
{
|
||||
test: /\.(html)$/,
|
||||
use: {
|
||||
loader: 'html-loader',
|
||||
options: {
|
||||
attrs: [':data-src']
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
To completely disable tag-attribute processing (for instance, if you're handling image loading on the client side) you can pass in `attrs=false`.
|
||||
|
||||
<h2 align="center">Examples</h2>
|
||||
@@ -102,6 +116,40 @@ module: {
|
||||
}
|
||||
```
|
||||
|
||||
See [html-minifier](https://github.com/kangax/html-minifier#options-quick-reference)'s documentation for more information on the available options.
|
||||
|
||||
The enabled rules for minimizing by default are the following ones:
|
||||
- removeComments
|
||||
- removeCommentsFromCDATA
|
||||
- removeCDATASectionsFromCDATA
|
||||
- collapseWhitespace
|
||||
- conservativeCollapse
|
||||
- removeAttributeQuotes
|
||||
- useShortDoctype
|
||||
- keepClosingSlash
|
||||
- minifyJS
|
||||
- minifyCSS
|
||||
- removeScriptTypeAttributes
|
||||
- removeStyleTypeAttributes
|
||||
|
||||
The rules can be disabled using the following options in your `webpack.conf.js`
|
||||
|
||||
```js
|
||||
module: {
|
||||
rules: [{
|
||||
test: /\.html$/,
|
||||
use: [ {
|
||||
loader: 'html-loader',
|
||||
options: {
|
||||
minimize: true,
|
||||
removeComments: false,
|
||||
collapseWhitespace: false
|
||||
}
|
||||
}],
|
||||
}]
|
||||
}
|
||||
```
|
||||
|
||||
### 'Root-relative' URLs
|
||||
|
||||
For urls that start with a `/`, the default behavior is to not translate them.
|
||||
|
||||
Reference in New Issue
Block a user