versioning

This plugin enables easy versioning for Payload collections.

Community 2 6/wk MIT v1.0.2

Installation

pnpm add @stefgootzen/payload-plugin-versioning

About

The Payload versioning plugin adds necessary fields and hooks for managing one-to-many relationships in collections. It introduces a 'versions' field to the base collection and a 'base' field to the version collection. This setup allows for automatic versioning and cascade behavior, ensuring that related versions are managed appropriately upon deletions. For configuration, users can utilize the `withVersioning` function in the Payload config, specifying which collections should have versioning enabled. An automatically incremented `versionNumber` field helps in keeping track of version history. Users can also create the first version upon the base document's creation through a simple configuration. This plugin targets users needing their versioning to reflect published states rather than just the latest document version. It offers a more user-friendly approach to version management in Payload CMS.

Package info

Package name
@stefgootzen/payload-plugin-versioning
Latest version
1.0.2
Unpacked size
35 kB
License
MIT
Weekly downloads
6
Last publish
Sep 8, 2025

Similar plugins

More in Content