Skip to content

create-block-interactive-template: README does not document available variants #76827

@juanmaguitar

Description

@juanmaguitar

Description

The @wordpress/create-block-interactive-template package currently exposes three variants in index.js, but the README makes no mention of them — not their names, not their purpose, and not how to invoke them.

Variants defined in index.js (but undocumented)

Variant Description
default Standard interactive block using the Interactivity API
typescript Interactive block using the Interactivity API with TypeScript
client-side-navigation Interactive block demonstrating client-side navigation via @wordpress/interactivity-router

Expected behaviour

The README should list all available variants with a short description of each, and show how to invoke them using the --variant flag, e.g.:

npx @wordpress/create-block --template @wordpress/create-block-interactive-template --variant typescript

Current README content

The README only documents the base usage command with no mention of variants:

npx @wordpress/create-block --template @wordpress/create-block-interactive-template

Why it matters

Without this documentation, users have no way to discover TypeScript support or the client-side navigation variant unless they read the package source. This is a significant discoverability problem, especially for new contributors exploring the Interactivity API.

Suggested fix

Add a "Variants" section to the README listing each variant, its purpose, the exact command to use it, and any additional dependencies it pulls in (e.g. @wordpress/interactivity-router for client-side-navigation).

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions