An open API service indexing awesome lists of open source software.

https://github.com/live-codes/codemirror


https://github.com/live-codes/codemirror

Last synced: 10 months ago
JSON representation

Awesome Lists containing this project

README

          

# @live-codes/codemirror

This is a custom build of CodeMirror6.

This was built for use in [LiveCodes](https://livecodes.io/).

## Usage

The editor is bundled as ESM. It can be used like this:

```html

import { basicSetup, lineNumbers, EditorView, javascript } from 'https://cdn.jsdelivr.net/npm/@live-codes/codemirror';

let view = new EditorView({
doc: "console.log('hello world');",
extensions: [
basicSetup,
lineNumbers(),
javascript(),
],
parent: document.querySelector('#container'),
})

```

## Build

```bash
npm run build
```

## License

MIT