Browse Source

Add support attribute module (#4091)

* Add support attribute module

To be able to use css-module

* Extend type SFCBlock

module?: string | boolean

* package vue-template-compiler update

* Revert "package vue-template-compiler update"

This reverts commit 0104458d631115d1abf8d7a6a694a1d84b9b0fc5.
dev
Victor Zakharenko 8 years ago
committed by Evan You
parent
commit
5a4c1d7f70
  1. 1
      flow/compiler.js
  2. 3
      src/sfc/parser.js

1
flow/compiler.js

@ -151,4 +151,5 @@ declare type SFCBlock = {
lang?: string;
src?: string;
scoped?: boolean;
module?: string | boolean;
}

3
src/sfc/parser.js

@ -61,6 +61,9 @@ export function parseComponent (
if (attr.name === 'scoped') {
block.scoped = true
}
if (attr.name === 'module') {
block.module = attr.value || true
}
if (attr.name === 'src') {
block.src = attr.value
}

Loading…
Cancel
Save