8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5f12086 commit a351d9eCopy full SHA for a351d9e
lib/coderay/scanners/java_script.rb
@@ -45,7 +45,7 @@ class JavaScript < Scanner
45
STRING_CONTENT_PATTERN = {
46
"'" => /[^\\']+/,
47
'"' => /[^\\"]+/,
48
- '/' => / (?: [^\\\/\[]+ | \[ ([^\]\\]+ | \\.)* \]? )+ /mx,
+ '/' => %r{ (?: [^\\/\[]+ | \[ ([^\]\\]+ | \\.)* \]? )+ }mx,
49
} # :nodoc:
50
KEY_CHECK_PATTERN = {
51
"'" => / (?> [^\\']* (?: \\. [^\\']* )* ) ' \s* : /mx,
0 commit comments