If you're ever looking to support TypeScript eventually, the Monaco editor (https://github.com/Microsoft/monaco-editor) is your place to go. This is the same codebase that powers VS Code, yet is browser compatible and can come with all the Intellisense you need!
EDIT: Actually it probably supports a variety languages
EDIT: Actually it probably supports a variety languages