Do not reload the buffer if no change.
Fix a bug for buffer switching.
Fixes truncate bug.
Fixes typos.
Adds javascript-mode.js.

There's a bug of regexp state, so just comment-out it.