vant-weapp/build/dev.js
2019-08-12 19:57:38 +08:00

16 lines
500 B
JavaScript

const fs = require('fs-extra');
const path = require('path');
const serve = require('webpack-serve');
const config = require('./webpack.doc.dev');
const dist = path.join(__dirname, '../example/dist');
const icons = path.join(__dirname, '../node_modules/@vant/icons');
const { exec } = require('child_process');
const gulpConfig = path.resolve(__dirname, './compiler.js');
fs.copySync(icons, path.join(dist, '/@vant/icons'));
serve({}, { config });
exec(`npx gulp -f ${gulpConfig} buildExample`);