-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Editor: Deprecate ServerSideRender in favour of @wordpress/server-side-render #21081
Conversation
Size Change: +24 B (0%) Total Size: 857 kB
ℹ️ View Unchanged
|
I'm wondering if this is seeking to update the canonical reference to the component, if we should first resolve the current issue of its naming. Since it is a React component, it would be expected to have the casing Previously: |
However verbose, what's wrong with |
@mcsf I don't have strong feelings against it, but in addition to being more verbose, there's a few other details to note:
Verbosity is likely more relevant for ES5 usage. In ES2015+, it would amount to the difference of a pair of squiggly brackets: import { ServerSideRender } from '@wordpress/server-side-render';
import ServerSideRender from '@wordpress/server-side-render'; |
Yes, all of those are good points. It seems we have bigger fish to fry then, and I'd rather not have such an unimportant PR as this one linger because of a pending decision. I'll close this. The broader topic seems like something for the Core JS group, don't you think? |
It's been discussed a few times, both in and out of the weekly meetings:
The sense from the conversation in 2018 was that it wasn't too important to be worrying over, or at least there wasn't a good convention for deprecations. Based on some of my later suggestions, I think we can still do a deprecation exactly like what was proposed in this pull request, but as part of an additional effort to introduce the implementation to assign the globals correctly. There's a JavaScript meeting a few minutes from now, I can plan to bring it up again there. I sense at this point it's more a matter of (a) getting an issue to track the effort and (b) actually doing it. |
Discussed during today's JavaScript chat (link requires registration): https://wordpress.slack.com/archives/C5UNMSU4R/p1585059454306400
|
Description
Use of component
wp.editor.ServerSideRender
now raises a deprecation warning recommendingwp.serverSideRender
as an alternative.Checklist: