0.0.5 • Published 4 years ago
@robotcoral/ngx-codemirror6 v0.0.5
ngx-codemirror6

Angular Component for CodeMirror 6
Installation
To use this component in your project install it via npm
npm i @robotcoral/ngx-codemirror6 @codemirror/basic-setup --saveUsing the component
Include CodeMirrorModule in your main module:
import { CodeMirrorModule } from "@robotcarol/ngx-codemirror6";
@NgModule({
// ...
imports: [CodeMirrorModule],
// ...
})
export class AppModule {}and add the ngx-codemirror selector to your feature component:
import { Component } from "@angular/core";
@Component({
selector: "sample",
template: ` <ngx-codemirror [config]="{...}"> </ngx-codemirror> `,
})
export class Sample {
// ...
}Configuration
You can pass an object of the type EditorStateConfig to the ngx-codemirror component via the [config] input.