Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Regular Expression
/
@font-face\s* # Match @font-face and some spaces ( # Start group 1 \{ # Match { (?: # A non-capturing group [^{}]+ # Match anything except {} one or more times | # Or (?1) # Recurse/rerun the expression of group 1 )* # Repeat 0 or more times \} # Match } ) # End group 1 (*SKIP)(*FAIL) # Skip it | # Or url\s*\( # Match url, optionally some whitespaces and then ( \s* # Match optionally some whitespaces ("|'|) # It seems that the quotes are optional according to http://www.w3.org/TR/CSS2/syndata.html#uri (?!["']?(?:https?://|ftp://)) # Put your negative-rules here (do not match url's with http, https or ftp) (?:[^\\]|\\.)*? # Match anything except a backslash or backslash and a character zero or more times ungreedy \2 # Match what was matched in group 2 \s* # Match optionally some whitespaces \) # Match )
/
gxs
Unit Tests
There are no unit tests, click
here
to add some.