docs: update configuration example to import plugin from the main entry

parent 7af8db40
......@@ -26,7 +26,7 @@ Vue Loader's configuration is a bit different from other loaders. In addition to
``` js
// webpack.config.js
const VueLoaderPlugin = require('vue-loader/lib/plugin')
const { VueLoaderPlugin } = require('vue-loader')
module.exports = {
module: {
......
......@@ -17,7 +17,7 @@ Vue Loader v15 now requires an accompanying webpack plugin to function properly:
``` js
// webpack.config.js
const VueLoaderPlugin = require('vue-loader/lib/plugin')
const { VueLoaderPlugin } = require('vue-loader')
module.exports = {
// ...
......
......@@ -26,7 +26,7 @@ npm install -D vue-loader vue-template-compiler
``` js
// webpack.config.js
const VueLoaderPlugin = require('vue-loader/lib/plugin')
const { VueLoaderPlugin } = require('vue-loader')
module.exports = {
module: {
......@@ -51,7 +51,7 @@ module.exports = {
``` js
// webpack.config.js
const VueLoaderPlugin = require('vue-loader/lib/plugin')
const { VueLoaderPlugin } = require('vue-loader')
module.exports = {
mode: 'development',
......
......@@ -17,7 +17,7 @@ Vue Loader v15 теперь для правильной работы требу
``` js
// webpack.config.js
const VueLoaderPlugin = require('vue-loader/lib/plugin')
const { VueLoaderPlugin } = require('vue-loader')
module.exports = {
// ...
......
......@@ -26,7 +26,7 @@ Vue Loader 的配置和其它的 loader 不太一样。除了通过一条规则
``` js
// webpack.config.js
const VueLoaderPlugin = require('vue-loader/lib/plugin')
const { VueLoaderPlugin } = require('vue-loader')
module.exports = {
module: {
......@@ -51,7 +51,7 @@ module.exports = {
``` js
// webpack.config.js
const VueLoaderPlugin = require('vue-loader/lib/plugin')
const { VueLoaderPlugin } = require('vue-loader')
module.exports = {
mode: 'development',
......
......@@ -17,7 +17,7 @@ Vue Loader v15 现在需要配合一个 webpack 插件才能正确使用:
``` js
// webpack.config.js
const VueLoaderPlugin = require('vue-loader/lib/plugin')
const { VueLoaderPlugin } = require('vue-loader')
module.exports = {
// ...
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment