The Home for Magento 2 Excellence

Quality-tested Magento 2 modules. Explore. Evaluate. Elevate. #magento2

1090 Modules
617 Ready
473 Need Help
🏆 Leaderboard
Stable v1.0.0

Yireo DumpCmsContent for Magento 2

yireo/magento2-dump-cms-content

Adds a CLI command (cms:dump) that exports all CMS pages and blocks to var/cms-output, enabling Tailwind CSS purge in Hyva builds to detect classes used inside database-stored content.

10,268
Downloads
Below average
17
GitHub Stars
Below average
8mo ago
Last Release
1
Open Issues
Build Passing
Ready to install

Build Tests

Composer Install
DI Compile
Templates

Code Quality

CS Coding Standard
9 warnings
L2 PHPStan

Tested on Magento 2.4.9

Recent Test History

Each release is tested against the latest Magento version at that time.

v1.0.0 on Magento 2.4.9
Jun 1, 2026

Share This Module's Status

Yireo DumpCmsContent for Magento 2 Magento compatibility status badge

README

Loaded from GitHub

Yireo DumpCmsContent

A Magento 2 module that adds a CLI bin/magento cms:dump to dump all CMS pages and CMS blocks to a folder var/cms-output.

Why?

This module was developed with Hyva Themes in mind: With a theme based on Hyva, your Tailwind CSS will need to be purged before going into production. For this, you would configure the Tailwind configuration to look into certain content folders to make sure CSS utility classes that are actually used, are not purged from the production CSS. Unfortunately, this does not work with the database.

Once you add Tailwind CSS classes to your CMS Blocks and CMS Pages (via the Magento Admin Panel, for instance by using some Tailwind-oriented WYSIWYG editor, or by inserting code manually), these CSS classes might or might not be purged, which could lead to incorrect CSS styling. To prevent this from happening, this module allows you to dump CMS contents to a folder var/cms-output, which could then be included in the Tailwind configuration:

module.exports = {
    ...
    purge: {
        content: [
            ...
            '../../../../../../../var/cms-output/**/*.html'
        ]
    }
}

This content is fetched directly from the module's GitHub repository. We are not the authors of this content and take no responsibility for its accuracy, completeness, or any consequences arising from its use.