Skip to content

Plugin: Include readable source files #23960

Open
@sirreal

Description

Is your feature request related to a problem? Please describe.

It's often helpful to include readable source files. There's a convention in WordPress to include minified and readable source files and to enqueue one or the other depending on the SCRIPT_DEBUG constant.

Gutenberg currently only includes minified JavaScript.

I propose the Gutenberg plugin follow the convention, including minified and readable JavaScript and enqueuing one or the other based on SCRIPT_DEBUG.

In this case readable source means unminified, bundled JavaScript packages. It does not mean all of the individual source files in the Gutenberg repository.

(See #23926 for a related change to use the .min.js convention)

Note: the plugin guidelines allow minified files to be included as long as there is a link to sources in a public repository. I consider this proposal to be an ideal, above and beyond plugin requirements.

This was discussed in the #core-editor meeting.

Metadata

Assignees

Labels

Gutenberg PluginIssues or PRs related to Gutenberg Plugin management related efforts[Status] In ProgressTracking issues with work in progress[Type] DiscussionFor issues that are high-level and not yet ready to implement.[Type] EnhancementA suggestion for improvement.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions