https://github.com/zedix/prose-editor-element
Prose Editor is a web component wrapping TipTap 2.
https://github.com/zedix/prose-editor-element
custom-elements lit rich-text-editor tiptap webcomponent wysiwyg-editor
Last synced: 9 months ago
JSON representation
Prose Editor is a web component wrapping TipTap 2.
- Host: GitHub
- URL: https://github.com/zedix/prose-editor-element
- Owner: zedix
- License: mit
- Created: 2023-08-28T17:05:21.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2024-04-07T21:53:54.000Z (about 2 years ago)
- Last Synced: 2025-04-19T10:37:51.968Z (about 1 year ago)
- Topics: custom-elements, lit, rich-text-editor, tiptap, webcomponent, wysiwyg-editor
- Language: TypeScript
- Homepage:
- Size: 1.07 MB
- Stars: 10
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Prose Editor
 [](https://github.com/lit/lit/)
Prose Editor is a web component wrapping [TipTap 2](https://www.tiptap.dev/).

## Demo
[Demo ↗](https://zedix-prose-editor-element.netlify.app)
## Installation
```
❯ yarn add @zedix/prose-editor-element
```
## Usage
This above global stylesheet is needed because ProseEditor must be in the light DOM (instead of the shadow tree) until these bugs are resolved:
- [Firefox #1496769](https://bugzilla.mozilla.org/show_bug.cgi?id=1496769)
- [WebKit #163921](https://bugs.webkit.org/show_bug.cgi?id=163921)
```css
@import '@zedix/prose-editor/dist/prose-editor.css';
```
```html
document.addEventListener('DOMContentLoaded', function () {
document
.querySelector('zx-prose-editor')
.addEventListener('change', function (event) {
console.log('HTML', event.detail.html);
console.log('JSON', event.detail.json);
});
});
```