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

Extract the edit-post module as a reusable package #10429

Merged
merged 6 commits into from Oct 9, 2018

Conversation

@youknowriad
Copy link
Contributor

youknowriad commented Oct 9, 2018

This PR extracts the edit-post package into the npm packages. The main reason is to make it usable in WordPress Core as a npm dependency. This package is not meant to be used outside the WordPress context though.

This is also the last Gutenberg package to move to the packages folder which means all of the Gutenberg JS code is a package now. There's only one deprecated component left at the root-level which will be able to remove in one or two releases.

@youknowriad youknowriad self-assigned this Oct 9, 2018
@youknowriad youknowriad requested review from gziolo and WordPress/gutenberg-core Oct 9, 2018
@@ -1,14 +1,13 @@
{
"name": "@wordpress/list-reusable-blocks",
"version": "1.0.1",
"version": "1.0.0-alpha.0",

This comment has been minimized.

Copy link
@gziolo

gziolo Oct 9, 2018

Member

Not sure if npm will allow downgrading

This comment has been minimized.

Copy link
@youknowriad

youknowriad Oct 9, 2018

Author Contributor

It was not released :)

This comment has been minimized.

Copy link
@gziolo

gziolo Oct 9, 2018

Member

it was as 1.0.1 - somehow private doesn't stop Lerna from publishing ...

This comment has been minimized.

Copy link
@youknowriad

youknowriad Oct 9, 2018

Author Contributor

I don't see it in npm, I think we're fine.

@gziolo gziolo force-pushed the add/edit-post-package branch from 04bd9be to 1057025 Oct 9, 2018
@@ -1,10 +0,0 @@
.edit-post-post-trash {

This comment has been minimized.

Copy link
@gziolo

gziolo Oct 9, 2018

Member

I confirm it can be safely removed. It's dead code.

@@ -265,16 +286,3 @@ body.gutenberg-editor-page {
}
}
}

This comment has been minimized.

Copy link
@gziolo

gziolo Oct 9, 2018

Member

I confirmed this with @iseulde that this is dead code which is no longer necessary.

@gziolo
gziolo approved these changes Oct 9, 2018
Copy link
Member

gziolo left a comment

I can confirm that everything still works as expected. I added a few commits so it would be nice to have another check for the code I added.

Amazing work @youknowriad on moving all remaining code to packages. This one marks another milestone. Looking forward to see the outcome of work started by @omarreiss and @atimmer to see it consumed in WordPress core.

@gziolo gziolo added this to the 4.0 milestone Oct 9, 2018
@youknowriad youknowriad merged commit 3d3c2a4 into master Oct 9, 2018
2 checks passed
2 checks passed
codecov/project 49.5% (+0.06%) compared to 8b4c97d
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@youknowriad youknowriad deleted the add/edit-post-package branch Oct 9, 2018
@youknowriad

This comment has been minimized.

Copy link
Contributor Author

youknowriad commented Oct 9, 2018

Thanks for the help @gziolo

Copy link
Member

tofumatt left a comment

This package is not meant to be used outside the WordPress context though.

Can you still have post-install messages for npm packages? Might be nice if our Gutenberg package displayed some kind of message for our (currently) WordPress-specific packages. 🤷‍♂️

@youknowriad

This comment has been minimized.

Copy link
Contributor Author

youknowriad commented Oct 9, 2018

@tofumatt seems like a good idea, we'll have to make sure it's not "a big warning" as the message will show up in WordPress Core and people should feel confident ignoring it.

@gziolo

This comment has been minimized.

Copy link
Member

gziolo commented Oct 9, 2018

Can we try to hide this message behind env flag so we could skip it in core?

@gziolo gziolo mentioned this pull request Oct 11, 2018
12 of 12 tasks complete
mzorz added a commit to wordpress-mobile/gutenberg-mobile that referenced this pull request Oct 11, 2018
@tofumatt tofumatt mentioned this pull request Oct 11, 2018
0 of 92 tasks complete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.