2.0.0-beta.1 • Published 9 years ago
tooling-preset-web v2.0.0-beta.1
tooling-preset-web
What this preset does:
- Generate
index.htmland relevant assets files - Copy
./static/**to./dist/** - CSS preprocessors (Postcss/Sass/Scss/Less/Stylus)
- CSS extraction
- Babel with
babel-preset-latest - Hot reloading (Live loading fallbacks) in
devcommand - Minimize and optimize in
buildcommand - Auto-split vendor code and app code in
buildcommand
Install
yarn add tooling-preset-web --devUsage
{
"tooling": {
"presets": [
"web"
]
}
}You can also use options:
{
"tooling": {
"presets": [
["web", {
"entry": "src/index.js"
}]
]
}
}Options
entry
Type: string
Default: index.js
Entry file.
dist
Type: string
Default: dist
Dist folder.
extract
Type: boolean
Default: true in build command
Extract CSS.
sourceMap
Type: boolean
Default: true in build command
Generate sourcemaps.
html
html-webpack-plugin options, the default value is:
{
title: 'Tooling Preset Web: Homepage'
}vendor
Type: boolean
Default: true in build command and only work in build command
Split vendor code and app code.
2.0.0-beta.1
9 years ago