Upgrade prosemirror-state occur RangeError: Adding different instances of a keyed plugin (plugin$)

Recently, I upgrade “prosemirror-state” from 1.3.4 to 1.4.1, and got above error. Would you like to upgrade “prosemirror-state” in a number of related core module such as “prosemirror-inputrules”, “prosemirror-keymap” etc. I guess that will help for solve this problem.

The version ranges in all those modules match the current version. Sometimes you need to clear your package lock and reinstall to make npm properly deduplicate packages.

1 Like

Thanks! It solves the problem, and this is my operations

  1. yarn add packages (updates version which in packages.json)
  2. yarn upgrade packages (updates version which in yarn.lock)