安装依赖包:
npm install art-template --save
npm install art-template-loader --save-dev
config.js配置:
rules: [
{
test: /\.art$/,
loader: "art-template-loader",
options: {
// art-template options (if necessary)
// @see https://github.com/aui/art-template
}
}
]
js中引入依赖:
const template = require('art-template/lib/template-web');