3.1.0 • Published 12 days ago
@nextlint/svelte v3.1.0
Nextlint
Nextlint is a WYSIWYG (What You See Is What You Get) editor built using the "@tiptap" library and developed with Svelte. It provides a user-friendly interface for editing and formatting text, allowing users to create rich content effortlessly.
Features
x Bubble Menu x Slash Menu x Image x GPT prompt Block Menu (WIP)
... and many more.
Demo:
https://nextlint-editor.vercel.app/
Quick start
Install the package:
//npm
npm install @nextlint/svelte
//yarn
yarn add @nextlint/svelte
//pnmp
npm add @nextlint/svelte
Setup
<script lang="ts">
import {type Editor, EditorTheme, SvelteEditor} from '@nextlint/svelte';
let editor: Editor;
const submitPromt = async (prompt: string) => {
// handle prompt for GPT plugin
return '';
};
const handleUpload = async (file: File) => {
// handle upload here
const blob = new Blob([file]);
const previewUrl = URL.createObjectURL(blob);
return previewUrl;
};
</script>
<EditorTheme>
<SvelteEditor
content={''}
placeholder="Press 'space' GPT support, type '/' for help"
onCreated={createdEditor => { editor = createdEditor }}
onChange={nextEditor => { editor = nextEditor }}
<!-- plugins config -->
plugins={{
selectImage: {
handleUpload,
unsplash: {
accessKey: 'UNPLASH_API_KEY'
}
},
gpt: {query: submitPromt}
}}
/>
</EditorTheme>
3.1.0
12 days ago
3.0.3
20 days ago
3.0.2
1 month ago
3.0.1
1 month ago
2.3.2
2 months ago
3.0.0
2 months ago
2.3.1
3 months ago
2.3.0
3 months ago
2.2.1
4 months ago
2.2.0
4 months ago
2.2.3
4 months ago
2.2.2
4 months ago
2.2.5
4 months ago
2.2.4
4 months ago
2.1.1
4 months ago
2.0.3
4 months ago
2.1.0
4 months ago
1.1.1
10 months ago
1.1.0
10 months ago
1.0.7
10 months ago
1.0.6
10 months ago
1.0.5
10 months ago
1.1.2
10 months ago
2.0.2
6 months ago
2.0.1
6 months ago
2.0.0
6 months ago
1.0.4
10 months ago
1.0.3
10 months ago
1.0.2
10 months ago
1.0.1
10 months ago