RightJS
The Right JavaScript Framework
RegExp
Methods
escape
RegExp.escape(String string) -> String new
Description
Escapes all the command characters in the string so it can safely be used as a part of a regular expression:
Example
RegExp.escape('[{!}]'); // -> "\[\{\!\}\]"