Dan Vanderkam
Dan Vanderkam
This would be great. I've done something similar to hack in JSX/Harmony support w/ blanket [here](https://github.com/danvk/mocha-react/blob/blanket/tests/blanket-stub-jsx.js).
@bsodzik can you say more about why clearing `require.cache` was insufficient to solve your problems? [Clearing it](https://github.com/danvk/mocha-react/commit/0ea74f2096b86294865bc1e39d49420c0fe03aee) in my `require.extensions` handler fixed a similar problem that I was having.
In case it's helpful to anyone... here's an example of how to incorporate something like @nielskrijger's comment: https://github.com/hammerlab/cycledash/pull/265
Yes, that would work for me. The use case for an individual track version would be if I wanted to log performance stats on individual loads, or re-style some elements...
Here are gists for the before/after: https://gist.github.com/danvk/be67220eb48cacc0a76c https://gist.github.com/danvk/1f772749c481f4da5fc3
Here's what the UI looks like in Gerrit: 
Gerrit doesn't seem to do this. Neither does Reviewable. I don't believe Critique did, either.
(an alternative way to implement this would be to make an effort to expand the diff hunk to include the function declaration)
Here's a [small demo](http://jsbin.com/xamidirifo/2/edit?html,css,js,output) based on how ReviewBoard handles this. The gist is that you style the left column cells to be un-selectable when the user clicks on the right...
cc @asmodehn