https://github.com/gitbookio/slate-no-empty
Slate plugin to prevent the document from being empty
https://github.com/gitbookio/slate-no-empty
Last synced: 9 months ago
JSON representation
Slate plugin to prevent the document from being empty
- Host: GitHub
- URL: https://github.com/gitbookio/slate-no-empty
- Owner: GitbookIO
- License: apache-2.0
- Created: 2017-06-09T15:55:13.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-06-09T15:56:55.000Z (over 8 years ago)
- Last Synced: 2025-04-19T14:59:26.229Z (9 months ago)
- Language: JavaScript
- Size: 25.4 KB
- Stars: 8
- Watchers: 3
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# slate-no-empty
[](http://badge.fury.io/js/slate-no-empty)
[](https://travis-ci.org/GitbookIO/slate-no-empty)
A Slate plugin to prevent the document from being empty.
### Install
```
npm install slate-no-empty --save
```
### Usage
```js
import NoEmpty from 'slate-no-empty'
const plugins = [
NoEmpty('paragraph')
// or NoEmpty(Block.create({ type: 'image', isVoid: true }))
]
```