visionmedia/node-requires — pull request #8 by anton-ryzhov (2014-09-25 13:42:17+00:00)
Title: Skip comments correctly

Current implementation has some bugs with comments parsing.
1. After using `stripComments` indexes is totally broken.
1. Library counts how many occurrences of `require` string has in code part (except comments) and then replaces string exact times, **including comments**. It replaces in comments and misses in code.

```js
// require("fooBar");
require("fooBar");
```
Library will replace first and miss second one.

`component.io` forgets to rewrite some URLs because of it.