(input: string, offset: number)
| 106 | ) |
| 107 | |
| 108 | function parse(input: string, offset: number): Program { |
| 109 | try { |
| 110 | return babelParse(input, { |
| 111 | plugins, |
| 112 | sourceType: 'module', |
| 113 | }).program |
| 114 | } catch (e: any) { |
| 115 | e.message = `[vue/compiler-sfc] ${e.message}\n\n${ |
| 116 | descriptor.filename |
| 117 | }\n${generateCodeFrame( |
| 118 | descriptor.source, |
| 119 | e.pos + offset, |
| 120 | e.pos + offset + 1, |
| 121 | )}` |
| 122 | throw e |
| 123 | } |
| 124 | } |
| 125 | |
| 126 | this.scriptAst = |
| 127 | descriptor.script && |
nothing calls this directly
no test coverage detected