Skip to content

Conversation

@kermanx
Copy link
Collaborator

@kermanx kermanx commented Jun 20, 2024

fix #2550.

Before After
image image

About the regex

(?:(?:(v-[\w-]+)(:)?)|([:\.])|(@)|(#))(?:(?:(\[)([^\]]*)(\]))|([\w-]+))?
                  |                         \
(?:(?:(v-[\w-]+)(:)?)|([:\.])|(@)|(#))   (?:(?:(\[)([^\]]*)(\]))|([\w-]+))?
   v-a                                      <omit>                      Then, modifiers or expression
   v-a:                                     [expr]
   #                                        attr-name
   :
   .
   @

@kermanx kermanx marked this pull request as draft June 20, 2024 10:45
@kermanx kermanx marked this pull request as ready for review June 20, 2024 10:59
@johnsoncodehk
Copy link
Member

This is awesome, thanks!

@johnsoncodehk johnsoncodehk merged commit 07f1f1d into vuejs:master Jun 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

自定义指令的语法高亮问题

2 participants