@lexical/headless
Advanced tools
Comparing version 0.13.1 to 0.14.0
@@ -12,3 +12,3 @@ /** @module @lexical/headless */ | ||
* Generates a headless editor that allows lexical to be used without the need for a DOM, eg in Node.js. | ||
* Throws an error when unsupported metehods are used. | ||
* Throws an error when unsupported methods are used. | ||
* @param editorConfig - The optional lexical editor configuration. | ||
@@ -15,0 +15,0 @@ * @returns - The configured headless editor. |
@@ -15,3 +15,3 @@ /** | ||
* Generates a headless editor that allows lexical to be used without the need for a DOM, eg in Node.js. | ||
* Throws an error when unsupported metehods are used. | ||
* Throws an error when unsupported methods are used. | ||
* @param editorConfig - The optional lexical editor configuration. | ||
@@ -18,0 +18,0 @@ * @returns - The configured headless editor. |
@@ -8,3 +8,3 @@ /** | ||
'use strict' | ||
const LexicalHeadless = process.env.NODE_ENV === 'development' ? require('./LexicalHeadless.dev.js') : require('./LexicalHeadless.prod.js') | ||
const LexicalHeadless = process.env.NODE_ENV === 'development' ? require('./LexicalHeadless.dev.js') : require('./LexicalHeadless.prod.js'); | ||
module.exports = LexicalHeadless; |
@@ -11,6 +11,6 @@ { | ||
"license": "MIT", | ||
"version": "0.13.1", | ||
"version": "0.14.0", | ||
"main": "LexicalHeadless.js", | ||
"peerDependencies": { | ||
"lexical": "0.13.1" | ||
"lexical": "0.14.0" | ||
}, | ||
@@ -21,3 +21,5 @@ "repository": { | ||
"directory": "packages/lexical-headless" | ||
} | ||
}, | ||
"module": "LexicalHeadless.esm.js", | ||
"sideEffects": false | ||
} |
# `@lexical/headless` | ||
[![See API Documentation](https://lexical.dev/img/see-api-documentation.svg)](https://lexical.dev/docs/api/modules/lexical_headless) | ||
This package allows you to interact with Lexical in a headless environment (one that does not rely on DOM, e.g. for Node.js environment), and use its | ||
@@ -43,3 +45,3 @@ main features like editor.update(), editor.registerNodeTransform(), editor.registerUpdateListener() | ||
const articleEditorStateJSON = await loadArticleBody(req.query.id); | ||
editor.setEditorState(editor.parseEditorState(articleEditorStateJSON)); | ||
editor.setEditorState(editor.parseEditorState(articleEditorStateJSON)); | ||
@@ -46,0 +48,0 @@ editor.update(() => { |
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
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
8450
11
102
54
2
1