This is a standalone example of using monaco-editor in React with a custom loader. For smaller projects it is more convenient to use a pre-bundled official version provided by Microsoft, rather than including the source in the project for bundling. Since the monaco codebase is fairly large (and not so ES6) it may various challenges for a model bundler like (esbuild, Rollup, etc). The advantages of this example are:
- small code size
- no dependency other than monaco-editor itself!
- close to "React" way of coding style
- functional React code
- highly customizable, no need for npm, etc
TBD
TBD
TBD
inspired by: