easywebpack-vue

vue webpack building solution for easywebpack

Usage no npm install needed!

<script type="module">
  import easywebpackVue from 'https://cdn.skypack.dev/easywebpack-vue';
</script>

README

easywebpack-vue

NPM version build status Test coverage David deps Known Vulnerabilities npm download

Webpack client render and server side render build solution for Vue

Featues

easywebpack

see easywebpack

Documents

Version

  • @easy-team/easywebpack-vue ^4.x.x > Webpack 4.x.x + Babel 7
  • easywebpack-vue ^4.x.x > Webpack 4.x.x + Babel 6
  • easywebpack-vue ^3.x.x > Webpack 3.x.x + Babel 6

Install

$ npm i @easy-team/easywebpack-vue --save-dev

Usage

webpack.config.js

const easywebpack = require('@easy-team/easywebpack-vue');
const webpack = easywebpack.webpack;
const merge = easywebpack.merge;
const baseWebpackConfig = easywebpack.getWebpackConfig({
    env, // support dev, test, prod 
    target : 'web', // browser mode build
    entry:{
        app: 'src/index.js'
    }
});
module.exports = merge(baseWebpackConfig, {
   
})

use webpack command build

webpack --config webpack.config.js

base easywebpacack-cli build mode

const webpackConfig = require('./webpack.config.js');

if (process.env.NODE_SERVER) {
  // development mode: webpack building and start webpack hot server
  easywebpack.server(config);
} else {
  // build file to disk
  easywebpack.build(config);
}

Example

Questions & Suggestions

Please open an issue here.

License

MIT