[MOOSE-372] FE: ServerSideRender should use named import#339
Open
GeoffDusome wants to merge 2 commits intomainfrom
Open
[MOOSE-372] FE: ServerSideRender should use named import#339GeoffDusome wants to merge 2 commits intomainfrom
ServerSideRender should use named import#339GeoffDusome wants to merge 2 commits intomainfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this do/fix?
This pull request updates all blocks that use the
ServerSideRenderpackage to import it as a named import instead of a default import, following the deprecation of the default import. This change ensures compatibility with the latest WordPress package standards and prevents potential issues with future updates.Refactoring imports for
ServerSideRender:ServerSideRenderacross multiple block editor files to use named imports (import { ServerSideRender } from '@wordpress/server-side-render';) instead of default imports. This affects blocks such asannouncement-renderer,icon-card,image-card,image-overlay-card,masthead-search,menu-toggle,post-card,related-posts,search-card, andterms(wp-content/themes/core/blocks/tribe/announcement-renderer/edit.js[1]wp-content/themes/core/blocks/tribe/icon-card/edit.js[2]wp-content/themes/core/blocks/tribe/image-card/edit.js[3]wp-content/themes/core/blocks/tribe/image-overlay-card/edit.js[4]wp-content/themes/core/blocks/tribe/masthead-search/edit.js[5]wp-content/themes/core/blocks/tribe/menu-toggle/edit.js[6]wp-content/themes/core/blocks/tribe/post-card/edit.js[7]wp-content/themes/core/blocks/tribe/related-posts/edit.js[8]wp-content/themes/core/blocks/tribe/search-card/edit.js[9]wp-content/themes/core/blocks/tribe/terms/edit.js[10]dev/templates/block/edit.js.mustache[11].CHANGELOG.mdto note the migration to named imports for all blocks using theServerSideRenderpackage.QA
Links to relevant issues
Dev Environment
Pull request checklist
I've captured a screenshot or screencast of the changes and linked it above.N/A