Use CodeMirror's Tern addon for the demo
[demo] Use hideDoc method
Fix mistake in docs (!def -> !define)

Closes #181
Resolve modules by the final filename used to read the source file (fixes issue where requiring the same module by 2 paths, one which explicitly includes the package.json "main" file and one which does not, orphans the AVal created by the first require call)