Skip to content

fauzi9331/codemirror-wrapped-line-indent

Repository files navigation

Wrapped Line Indentation for CodeMirror

An extension for CodeMirror that adds indentation for wrapped lines.

Installation

Using npm:

npm install codemirror-wrapped-line-indent

Usage

import { EditorState } from '@codemirror/state';
import { EditorView } from '@codemirror/view';
import { wrappedLineIndent } from 'codemirror-wrapped-line-indent';

// ... your CodeMirror setup code ...

const state = EditorState.create({
  // ... other state options ...
  extensions: [
    EditorView.lineWrapping,
    wrappedLineIndent
  ]
});

const view = new EditorView({ state });

License

MIT

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published