Socket
Socket
Sign inDemoInstall

@types/prosemirror-history

Package Overview
Dependencies
7
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.2 to 1.0.3

2

prosemirror-history/index.d.ts

@@ -28,3 +28,3 @@ // Type definitions for prosemirror-history 1.0

*/
export function history(config?: { depth?: number | null; newGroupDelay?: number | null }): Plugin;
export function history(config?: { depth?: number | null | undefined; newGroupDelay?: number | null | undefined }): Plugin;
/**

@@ -31,0 +31,0 @@ * A command function that undoes the last change, if any.

{
"name": "@types/prosemirror-history",
"version": "1.0.2",
"version": "1.0.3",
"description": "TypeScript definitions for prosemirror-history",
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/prosemirror-history",
"license": "MIT",

@@ -40,4 +41,4 @@ "contributors": [

},
"typesPublisherContentHash": "e02e2135c6358d50c52010f5d88d06220a4eebfd75fd59b3b1e3f0802ada0034",
"typeScriptVersion": "3.4"
"typesPublisherContentHash": "30c693fba86517e88e201633823c4505f12caea481f0d5285bc398354dba037c",
"typeScriptVersion": "3.6"
}

@@ -9,5 +9,53 @@ # Installation

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/prosemirror-history.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/prosemirror-history/index.d.ts)
````ts
// Type definitions for prosemirror-history 1.0
// Project: https://github.com/ProseMirror/prosemirror-history
// Definitions by: Bradley Ayers <https://github.com/bradleyayers>
// David Hahn <https://github.com/davidka>
// Tim Baumann <https://github.com/timjb>
// Patrick Simmelbauer <https://github.com/patsimm>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.3
import { Schema } from 'prosemirror-model';
import { EditorState, Plugin, Transaction } from 'prosemirror-state';
/**
* Set a flag on the given transaction that will prevent further steps
* from being appended to an existing history event (so that they
* require a separate undo command to undo).
*/
export function closeHistory<S extends Schema = any>(tr: Transaction<S>): Transaction<S>;
/**
* Returns a plugin that enables the undo history for an editor. The
* plugin will track undo and redo stacks, which can be used with the
* [`undo`](#history.undo) and [`redo`](#history.redo) commands.
*
* You can set an `"addToHistory"` [metadata
* property](#state.Transaction.setMeta) of `false` on a transaction
* to prevent it from being rolled back by undo.
*/
export function history(config?: { depth?: number | null | undefined; newGroupDelay?: number | null | undefined }): Plugin;
/**
* A command function that undoes the last change, if any.
*/
export function undo<S extends Schema = any>(state: EditorState<S>, dispatch?: (tr: Transaction<S>) => void): boolean;
/**
* A command function that redoes the last undone change, if any.
*/
export function redo<S extends Schema = any>(state: EditorState<S>, dispatch?: (tr: Transaction<S>) => void): boolean;
/**
* The amount of undoable events available in a given state.
*/
export function undoDepth(state: EditorState): number;
/**
* The amount of redoable events available in a given editor state.
*/
export function redoDepth(state: EditorState): number;
````
### Additional Details
* Last updated: Mon, 18 Jan 2021 15:07:06 GMT
* Last updated: Wed, 07 Jul 2021 17:02:38 GMT
* Dependencies: [@types/prosemirror-model](https://npmjs.com/package/@types/prosemirror-model), [@types/prosemirror-state](https://npmjs.com/package/@types/prosemirror-state)

@@ -14,0 +62,0 @@ * Global values: none

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc