Skip to content

Commit

Permalink
GraphQl: Optimized regexes (#3136)
Browse files Browse the repository at this point in the history
  • Loading branch information
RunDevelopment committed Oct 5, 2021
1 parent 05e7ab0 commit 8494519
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions components/prism-graphql.js
Expand Up @@ -24,11 +24,11 @@ Prism.languages.graphql = {
alias: 'function'
},
'attr-name': {
pattern: /[a-z_]\w*(?=\s*(?:\((?:[^()"]|"(?:\\.|[^\\"\r\n])*")*\))?:)/i,
pattern: /\b[a-z_]\w*(?=\s*(?:\((?:[^()"]|"(?:\\.|[^\\"\r\n])*")*\))?:)/i,
greedy: true
},
'atom-input': {
pattern: /[A-Z]\w*Input(?=!?.*$)/m,
pattern: /\b[A-Z]\w*Input\b/,
alias: 'class-name'
},
'scalar': /\b(?:Boolean|Float|ID|Int|String)\b/,
Expand Down
2 changes: 1 addition & 1 deletion components/prism-graphql.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 8494519

Please sign in to comment.