draft-js-cleanup-empty-plugin
Advanced tools
Comparing version 1.0.2 to 2.0.0-beta.2
@@ -18,4 +18,6 @@ 'use strict'; | ||
var types = []; | ||
var cleanupEmptyPlugin = function cleanupEmptyPlugin(options) { | ||
types = options.types || []; | ||
var cleanupEmptyPlugin = function cleanupEmptyPlugin() { | ||
var config = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0]; | ||
types = config.types || []; | ||
return { | ||
@@ -22,0 +24,0 @@ handleKeyCommand: function handleKeyCommand(command, _ref) { |
{ | ||
"name": "draft-js-cleanup-empty-plugin", | ||
"version": "1.0.2", | ||
"version": "2.0.0-beta.2", | ||
"description": "Cleanup empty Plugin for DraftJS", | ||
@@ -24,8 +24,2 @@ "author": { | ||
], | ||
"peerDependencies": { | ||
"draft-js": ">=0.5.0", | ||
"immutable": ">=3.7.6", | ||
"react": ">=0.14.0 || 15.0.0-rc", | ||
"react-dom": ">=0.14.0 || 15.0.0-rc" | ||
}, | ||
"scripts": { | ||
@@ -41,4 +35,8 @@ "clean": "../node_modules/.bin/rimraf lib", | ||
"find-with-regex": "^1.0.2", | ||
"union-class-names": "^1.0.0" | ||
"union-class-names": "^1.0.0", | ||
"draft-js": ">=0.7.0", | ||
"immutable": ">=3.8.1", | ||
"react": ">=15.1.0", | ||
"react-dom": ">=15.1.0" | ||
} | ||
} |
@@ -1,1 +0,17 @@ | ||
# State Plugin | ||
# DraftJS Cleanup Plugin | ||
*This is a plugin for the `draft-js-plugins-editor`.* | ||
Usage: | ||
```js | ||
import createCleanupEmptyPlugin from `draft-js-cleanup-empty-plugin`; | ||
const cleanupPlugin = createCleanupEmptyPlugin({ | ||
types: [] | ||
}); | ||
``` | ||
Dependencies: | ||
This plugin requires that the `draft-js-entity-props-plugin` is also applied to the `Editor`; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6193
98
18
2
+ Addeddraft-js@>=0.7.0
+ Addedimmutable@>=3.8.1
+ Addedreact@>=15.1.0
+ Addedreact-dom@>=15.1.0