Merge pull request #1577 from kaven276/vue-sections-fix
vue section mark right
This commit is contained in:
commit
40a07b29e9
|
@ -12,7 +12,7 @@ module.exports = class VueBeautifier extends Beautifier
|
|||
|
||||
beautify: (text, language, options) ->
|
||||
return new @Promise((resolve, reject) ->
|
||||
regexp = /(<(template|script|style)[^>]*>)((\s|\S)*?)<\/\2>/gi
|
||||
regexp = /(^<(template|script|style)[^>]*>)((\s|\S)*?)^<\/\2>/gim
|
||||
|
||||
resolve(text.replace(regexp, (match, begin, type, text) ->
|
||||
lang = /lang\s*=\s*['"](\w+)["']/.exec(begin)?[1]
|
||||
|
|
Loading…
Reference in New Issue