Inkio
Inkio๋ Tiptap ๊ธฐ๋ฐ์ ๋ ์ด์ด๋ ์๋ํฐ ํจํค์ง ๋ชจ์์ ๋๋ค.
์์์
@inkio/simple- classic WYSIWYG
- toolbar-first
- ๊ฐ์ฅ ์ฌ์ด ์์์
@inkio/editor- notion-like
- bubble/floating menu, slash command, block handle ์ค์ฌ
@inkio/advanced- comments, mention, hashtag, wiki link ๊ฐ์ ๊ณ ๊ธ ํ์ฅ
@inkio/image-editorImageBlock์ฉ ์ด๋ฏธ์ง ํธ์ง UI
๊ณตํต ์คํ์ผ ์ธ์ด
ํจํค์ง๋ณ ๋ฐฐ์น๋ ๋ค๋ฆ ๋๋ค.
@inkio/simple: classic toolbar-first@inkio/editor: notion-like@inkio/image-editor: fullscreen overlay
๋์ chrome surface๋ ๊ณตํต Inkio token์ ๊ณต์ ํฉ๋๋ค.
shell: toolbar, dock, command bar, sidebarpanel: popover, floating card, pickerfield: input, select, textarea, search
๋น ๋ฅธ ์ค์น
Classic:
npm install @inkio/simple react react-domNotion-like:
npm install @inkio/editor react react-dom์ต์ ํจํค์ง:
npm install @inkio/image-editorCommentPanel ๊ฐ์ advanced export๋ฅผ ์ฑ ์ฝ๋์์ ์ง์ importํ ๋๋ง @inkio/advanced๋ฅผ ์ถ๊ฐ ์ค์นํฉ๋๋ค.
์์
import { Editor } from '@inkio/simple';
import '@inkio/simple/minimal.css';
export function Page() {
return <Editor initialContent="<p>Hello Inkio</p>" />;
}Markdown์ ์๋ธํจ์ค๋ก ์ ๊ณตํฉ๋๋ค.
import { parseMarkdown, stringifyMarkdown } from '@inkio/simple/markdown';๊ตฌํ์ remark/unified ๊ธฐ๋ฐ์ด๋ฉฐ markdown๊ณผ JSONContent๋ฅผ ์ง์ ๋ณํํฉ๋๋ค.
Last updated on