Cassette CMF

The content modeling framework built for WordPress plugin developers. Delivers custom post types, taxonomies, settings pages, and custom fields all in a single config file.

Lean. Extensible. Beautiful.

composer require pedalcms/cassette-cmf

A library, not a plugin.

We don't even support using it as a plugin because we want to focus 100% on the library experience.

Config Arrays, Not Method Calls

Define everything in arrays or JSON in just one method call. Super clean.

CPTs + Taxonomies + Fields + Settings Pages Together

One config array registers your entire content model.

Modular by Design

18 field types in core. Additional fields will be available as separate Composer packages. Include only what you need.

Here's what it looks like:

use PedalCMS\CassetteCMF\Core\Manager;

/* Set up on `init` or after, just like using `register_post_type`. */ 
add_action('init', function() {
    Manager::init()->register_from_array([
        'cpts' => [
            [
                'id' => 'book',
                'args' => ['label' => 'Books', 'public' => true],
                'taxonomies' => [
                    ['id' => 'genre', 'args' => ['label' => 'Genres']],
                ],
                'fields' => [
                    ['name' => 'isbn', 'type' => 'text', 'label' => 'ISBN'],
                    ['name' => 'author', 'type' => 'text', 'label' => 'Author'],
                ],
            ],
        ],
    ]);
});

One array. CPT registered. Taxonomy attached. Fields in the meta box. All version controlled.

😳 Why build yet another WordPress custom field solution?

Shockingly, none of the existing solutions scratched our itch.

We needed:

  • Install via composer (narrows it down to ACF and Carbon Fields)
  • Config based (eliminates Carbon Fields)
  • Fully featured without a premium license (eliminates ACF)

Don't get us wrong! We have the utmost respect for ACF, Carbon Fields, and all the rest of the community who have solved this particular problem countless times. We just needed something that wasn't available.

We hope you'll find it useful too.

Field Types

Additional fields will be available as separate Composer packages. That's the point: keep core lean.

Missing a field you need?

You can build your own fields using our Field API with minimal effort.

How Cassette CMF compares:

Feature Cassette CMF ACF Carbon Fields
Totally Free
Number of Fields 18 35 27
Modular Design
Conditional Fields Not Yet
Repeater Fields Pro only
Relationship Fields Not yet
Register CPTs & Taxonomies
Create Gutenberg Blocks Potential Addon
Field Definitions PHP arrays / JSON PHP arrays / JSON / Syncable UI PHP fluent method-chaining API
Admin UI
Install via Composer
Install Size (unzipped) 549 KB(v0.0.5) 25.8 MB (v6.7.2 Pro) 9.8 MB (v3.6.9)
Number of Installs <10 2M+ ~300

Want more feature comparisons?

Scott Kingsley Clark maintains an exhaustive comparison chart covering similar solutions.

FAQs

Does this work with existing post types and taxonomies?

It does! You can use it with native post types and taxonomies (posts, pages, tags, categories), your own CPTs that are already registered another way, or even third party post types and taxonomies.

Can I use this as a plugin?

You absolutely could. It would be trivial to build a plugin wrapper around this library. We're not including that because we are hardcore about not including anything not aimed at the main audience of plugin developers.

Can I use this as theme developer or site builder?

Of course!

If you use Composer in your stack, you can use this library. Honestly, you don't really need Composer; you could download the release and bundle it by hand. But then you wouldn't have a built-in update mechanism, so we don't recommend that.

Can I use this outside of WordPress?

No. It is built specifically for WordPress and is dependent on it.

Why no Map field or icon field?

While those are incredibly common and incredibly useful, both require choosing third party services or packages for you. If we pick Google Maps and Font Awesome but you're using Mapbox and Lucide, our fields don't help you. And that's a bunch of code and icons you won't use but still have installed. That runs counter to our entire lean core with addon packages design.

Why does package size matter?

If you're only installing the package once, maybe it doesn't matter to you.

But imagine you want to build five plugins that all require custom fields or settings, all are independent of each other, and your ideal case is that users install all five. Obviously, you need a fields package (homegrown or OTS) to stay as DRY as possible.

If you go with ACF Pro, that's about 125MB worth of code, just for your fields package. And every backup of your customer's site has to include that as well. With multiple backups, it adds up.

Why "Cassette"?

We're Pedal. We like bike metaphors.

On a bike, the cassette is the cluster of sprockets on the rear wheel. Most people don't know it's called that; they just pedal and and switch gears and everything just works. Essential to the system, invisible to the rider.

That's what we want for you. Cassette CMF does its job. Nobody notices. Everything just works.

Ready to try it?

composer require pedalcms/cassette-cmf

Requires PHP 8.2+ and WordPress 6.0+