Krinkle/mw-gadgets-jsUpdater — pull request #3 by helder-git (2012-05-20 13:49:02+00:00)
Title: Adding regex (and tests) for converting $j → $

I was able to use the test suite and found out the replace was not working as I expected. This behavior is new to me:
```
alert( [
'Aa'.replace(/(A|a)/g, '<$1>') === '',
'Aa'.replace(/(A|a)/g, '<$$1>') === '<$1><$1>', // why?
'Aa'.replace(/(A|a)/g, '<$$$1>') === '<$A><$a>',
'Aa'.replace(/(A|a)/g, '<$$$$1>') === '<$$1><$$1>' // why?
] );```
returns "true,true,true,true" (on FF 12 and Chrome 19, at least). So I had to add one more "$" to the replacement.