Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add requirements to meet WordPress.org block directory guidelines #63

Merged
merged 6 commits into from Aug 11, 2020

Conversation

jeffpaul
Copy link
Member

@jeffpaul jeffpaul commented Jul 9, 2020

Description of the Change

#62 outlines what's needed fairly well, this PR adds the block tag to readme.txt and the block.json file. I'm leaving this as a draft PR as the block.json still needs the scripts/styles added to the end of it as well as validating all other fields that I've attempted to complete. Note that there's duplication of the attributes and icon in the block.json with other places in the plugin codebase as I copied those values into the block.json file, I'm not certain if we can or should remove other references as the block submission guidelines and other details are still a bit in flux.

Alternate Designs

n/a

Benefits

Ensures that this plugin appears in the Block Directory search within Gutenberg.

Possible Drawbacks

Given that we've got PHP code for the Settings page, we may need to get manual approval from the Plugin Review Team as there's supposed to be minimal-to-no PHP code in "block plugins".

Verification Process

TBD as this is still WIP, haven't verified anything fully yet.

Checklist:

  • I have read the CONTRIBUTING document.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my change.
  • All new and existing tests passed.

Applicable Issues

Closes #62.

Changelog Entry

### Added
- WordPress.org Block Directory integration

@jeffpaul jeffpaul added this to the 1.0.1 milestone Jul 9, 2020
@jeffpaul jeffpaul self-assigned this Jul 9, 2020
I _think_ this is closer to what WordPress.org is looking for
@fabiankaegy
Copy link
Member

@jeffpaul My main concern is the custom REST endpoint. And we would need to remove the settings page. Because there can be no UI outside the editor

@jeffpaul
Copy link
Member Author

@fabiankaegy yes, the "no PHP" stance is a current issue for us though I'm discussing with folks over in core about this in cases for blocks that need some setup/config steps that ideally happens in a Settings page. I know that the Plugin Review Team can add a block plugin to the Block Directory themselves, so I'm hoping our case at worst is an exception to the rule until the Gutenberg team is able to provide a better way to handle block setup/config akin to a Settings page. For now let's keep our settings as-is and only change if the Plugin Review Team and Gutenberg team say we must change.

@jeffpaul
Copy link
Member Author

@fabiankaegy @ryanwelcher I could use your help in confirming the styles/scripts to reference in the block.json file, noting details on these potential four entries starts here: https://github.com/WordPress/gutenberg/blob/master/docs/rfc/block-registration.md#editor-script

block.json Outdated Show resolved Hide resolved
@jeffpaul jeffpaul added the type:enhancement New feature or request. label Jul 29, 2020
@jeffpaul jeffpaul marked this pull request as ready for review July 29, 2020 19:17
@jeffpaul jeffpaul mentioned this pull request Aug 10, 2020
15 tasks
@jeffpaul
Copy link
Member Author

Sharing a screenshot from @fabiankaegy of request changes, I'll update for these now. Screen Shot 2020-08-11 at 18 33 00

@jeffpaul
Copy link
Member Author

Per https://github.com/WordPress/gutenberg/blob/master/docs/designers-developers/developers/block-api/block-metadata.md it looks like we'll need to keep the file: prepended to the scripts/styles at the end of the block.json file.

@jeffpaul jeffpaul merged commit 1b0da64 into develop Aug 11, 2020
@jeffpaul jeffpaul mentioned this pull request Aug 11, 2020
@jeffpaul jeffpaul deleted the add/block-directory branch February 18, 2021 21:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:enhancement New feature or request.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Prepare for Block Directory
2 participants