Skip to content

Commit

Permalink
fix: force reload on SFC scoped status change
Browse files Browse the repository at this point in the history
fix #348
  • Loading branch information
yyx990803 committed Jun 4, 2020
1 parent fc59642 commit 1a7243a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/node/server/serverPluginVue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -223,8 +223,9 @@ export const vuePlugin: ServerPlugin = ({
return sendReload()
}

// force reload if scoped status has changed
if (prevStyles.some((s) => s.scoped) !== nextStyles.some((s) => s.scoped)) {
needRerender = true
return sendReload()
}

// only need to update styles if not reloading, since reload forces
Expand Down

0 comments on commit 1a7243a

Please sign in to comment.