npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@burhanshaikh/strapi-plugin-content-versioning

v1.4.6

Published

Content Versioning & Revision Control plugin for Strapi 5 with deep document preview and instant revert

Readme

@burhanshaikh/strapi-plugin-content-versioning

npm version License: MIT Strapi 5

A production-grade, schema-agnostic Content Versioning & Revision Control plugin built specifically for Strapi 5.

Easily manage revision histories, deeply inspect historical snapshots (including nested components, repeatable fields, dynamic zones, and media), and instantly revert back to any previous version with 1-click directly from the Strapi Content Manager.


✨ Features

  • 🕒 Revision History Modal: Accessible directly from the header of the Strapi Content Manager edit view.
  • 👁️ Deep Revision Preview:
    • Open a dedicated popup preview for any revision (both past snapshots and active documents).
    • Structured Document View: Displays all content fields in a clean, readable layout.
    • Deep Dynamic Zones & Nested Components: Fully inspects dynamic zones, repeatable components, nested components, and media assets with image previews.
    • Raw JSON View: Inspect the complete raw snapshot with syntax highlighting and a 1-click Copy JSON button.
  • 🔄 Instant 1-Click Revert: Safely restore content fields, dynamic zones, nested components, and relation references into your active draft entry without manual copy-pasting.
  • 🔢 Sequential Version Numbers: Clear, ascending revision numbers (1, 2, 3...), always keeping the active version highlighted with a CURRENT badge.
  • 🛡️ Unique Constraint & DB Safety: Prevents PostgreSQL, SQLite, and MySQL unique key constraint conflicts by safely suffixing historic snapshots while preserving clean URLs and slugs for active/published entries.
  • 📦 Auto-Retention (Max 10 Revisions): Keeps database storage lightweight and optimized by maintaining up to 10 sequential revisions (9 historic snapshots + 1 active) and automatically purging older snapshots.
  • ⚡ 100% Schema-Agnostic: Zero hardcoded models or fields. Operates cleanly with any collection type, single type, component structure, or localized content.

⚙️ Installation

Install the package in your Strapi project:

# Using npm
npm install @burhanshaikh/strapi-plugin-content-versioning

# Using yarn
yarn add @burhanshaikh/strapi-plugin-content-versioning

🔧 Configuration

Enable the plugin in your Strapi configuration:

JavaScript (config/plugins.js)

module.exports = {
  // ...
  'content-versioning': {
    enabled: true,
  },
};

TypeScript (config/plugins.ts)

export default {
  // ...
  'content-versioning': {
    enabled: true,
  },
};

📝 Enabling Versioning on Content Types

To enable revision control for a content type:

Option A: Via Content-Type Builder UI

  1. Go to Content-Type Builder in the Strapi admin panel.
  2. Edit your desired collection or single type.
  3. Click the Advanced Settings tab.
  4. Check Enable content versioning and save.

Option B: Via schema.json

Add pluginOptions.versions.versioned: true to the content type's schema.json:

{
  "kind": "collectionType",
  "collectionName": "articles",
  "info": {
    "singularName": "article",
    "pluralName": "articles",
    "displayName": "Article"
  },
  "options": {
    "draftAndPublish": true
  },
  "pluginOptions": {
    "versions": {
      "versioned": true
    }
  },
  "attributes": {
    ...
  }
}

Rebuild your Strapi admin panel:

npm run build
npm run dev

🚀 How to Use

  1. Open any versioned entry in the Strapi Content Manager.
  2. Click the Revisions action button in the top right header bar.
  3. In the Revisions modal:
    • Preview: Click the eye icon next to any revision to open the Revision Preview popup. Switch between Document Fields (structured components, dynamic zones, media) and Raw JSON.
    • Revert: Click Revert next to any previous revision to restore its content into your current entry.
  4. Review the restored fields and click Save or Publish when ready.

👨‍💻 Author & Repository


📄 License

MIT © 2026 BurhanShaikh-9