From b9268df91b16ddbebc65f09f642d7a0d3335526c Mon Sep 17 00:00:00 2001 From: Clark Du Date: Thu, 30 Nov 2017 14:03:25 +0800 Subject: [PATCH] fix(dev-watching): mixins not removed after function changed or deleted --- lib/builder/builder.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/builder/builder.js b/lib/builder/builder.js index 1325cc2ca8..45c57269c0 100644 --- a/lib/builder/builder.js +++ b/lib/builder/builder.js @@ -459,6 +459,9 @@ export default class Builder { compiler.watch(this.options.watchers.webpack, (err) => { /* istanbul ignore if */ if (err) return reject(err) + // not keep modified or deleted items in Vue.prototype + delete require.cache[require.resolve('vue')] + delete require.cache[require.resolve('vue-router')] }) ) return