JSPM

@editora/code

1.0.3
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 157
  • Score
    100M100P100Q41089F
  • License MIT

Source Code Editor plugin for Rich Text Editor

Package Exports

  • @editora/code

Readme

@editora/code

Version License TypeScript Size

[!IMPORTANT] Live Website: https://editora-ecosystem.netlify.app/
Storybook: https://editora-ecosystem-storybook.netlify.app/

Source view plugin for Editora rich text editor.

What It Does

  • Toggles source-editor mode for HTML editing.
  • Uses codejar and highlight.js for lightweight code editing/highlighting.
  • Allows direct source modifications and write-back to editor content.

Installation

npm install @editora/code

Or bundled plugins:

npm install @editora/plugins

Usage

import { CodePlugin } from "@editora/code";
// or: import { CodePlugin } from "@editora/plugins";

const plugins = [CodePlugin()];

Command and Shortcut

  • Command: toggleSourceView
  • Shortcut: Mod-Shift-S

Notes

  • Source dialog supports large content editing, search interactions, and apply/cancel flows.