]> git.ipfire.org Git - thirdparty/vuejs/core.git/commitdiff
chore: todos
authorEvan You <yyx990803@gmail.com>
Thu, 28 Nov 2019 20:22:30 +0000 (15:22 -0500)
committerEvan You <yyx990803@gmail.com>
Thu, 28 Nov 2019 20:22:30 +0000 (15:22 -0500)
packages/compiler-sfc/__tests__/parse.spec.ts
packages/compiler-sfc/src/parse.ts

index 75ed1196869bbdf06338925bb777f5880df2d1f3..d3b5330a8c016ab17c3c1164667c7ff6604d4a38 100644 (file)
@@ -8,11 +8,13 @@ describe('compiler:sfc', () => {
     test('style block', () => {
       const style = parse(`<style>\n.color {\n color: red;\n }\n</style>\n`)
         .styles[0]
+      // TODO need to actually test this with SourceMapConsumer
       expect(style.map).not.toBeUndefined()
     })
 
     test('script block', () => {
       const script = parse(`<script>\nconsole.log(1)\n }\n</script>\n`).script
+      // TODO need to actually test this with SourceMapConsumer
       expect(script!.map).not.toBeUndefined()
     })
   })
index bb82d8a440dc9c894932d6c6ff658d667c435bf4..e37dbb981ca9d0f81d7d85aa0abcf9cf60606363 100644 (file)
@@ -74,6 +74,7 @@ export function parse(
     styles: [],
     customBlocks: []
   }
+
   const ast = baseParse(source, {
     isNativeTag: () => true,
     getTextMode: () => TextModes.RAWTEXT
@@ -86,6 +87,7 @@ export function parse(
     if (!node.children.length) {
       return
     }
+    // TODO handle pad option
     switch (node.tag) {
       case 'template':
         if (!sfc.template) {