Skip to content
This repository was archived by the owner on Jun 19, 2025. It is now read-only.
This repository was archived by the owner on Jun 19, 2025. It is now read-only.

README is not clear how to use the examples to build and deploy a esnext plugin #180

Open

Description

@T-Gwynbleidd

I'm new to Gutenberg Block creation, and found this example repo through the official documentation.
The README mentions npm run build to compile the blocks for build deployment, but not what should be extracted into a zip file to upload as a plugin.

I've tried searching online, but there's no clarity. Is it possible to provide clearer steps?

I can use this example repo to get a local instance running, and see my changes to the edit & saved version of the plugin.
What I would love is to know how to take the minimal build files, separate it from the node modules etc and upload it to another site.
I can't see what is happening right now on the local site behind the scenes as it's running using Docker.

Activity

  1. ryanwelcher commented on Mar 30, 2022

    @ryanwelcher
    Contributor

    With the current structure of the plugin, you would need to remove all of the src folders in each example along with the vendor and node_modules directory. There are also a number of files at the root of the project that could be removed as well:

    • .gitignore
    • .editorConfig
    • .nvmrc
    • composer.json
    • composer.lock
    • lerna.json
    • package.json
    • package-lock.json
    • phpcs.xml

    We are working towards restructuring the project to make this process much easier ( see #195 ) and would allow us to leverage the package-zip command from the @wordpress/scripts package

  2. T-Gwynbleidd commented on Apr 3, 2022

    @T-Gwynbleidd
    Author

    Thanks for getting back to me on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions