mirror of
https://github.com/ueberdosis/tiptap.git
synced 2025-01-21 08:38:19 +08:00
1.3 KiB
1.3 KiB
Installation
tiptap has a very modular package structure and is independent of any framework. If you want to start as fast as possible, you need at least the two packages @tiptap/core
and @tiptap/starter-kit
.
# Using npm
npm install @tiptap/core @tiptap/starter-kit
# Using Yarn
yarn add @tiptap/core @tiptap/starter-kit
You can use it like this:
Vanilla JavaScript
import { Editor } from '@tiptap/core'
import extensions from '@tiptap/starter-kit'
new Editor({
element: document.getElementsByClassName('element'),
extensions: extensions(),
content: '<p>Hey there.</p>',
})
- Play with tiptap on CodeSandbox
Vue.js
To use tiptap with Vue.js and tools that are based on Vue.js install the Vue.js adapter in your project:
# Using npm
npm install @tiptap/core @tiptap/starter-kit @tiptap/vue
# Using Yarn
yarn add @tiptap/core @tiptap/starter-kit @tiptap/vue
Create a new component and add the following content to get a basic version of tiptap:
- Read more about Using tiptap with Vue.js
- Play with tiptap on CodeSandbox
React
// TODO
- Play with tiptap on CodeSandbox
CDN
// TODO