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

Find better location for __experimentalFetchRichUrlData function #32725

Closed
Tracked by #35073
getdave opened this issue Jun 16, 2021 · 1 comment
Closed
Tracked by #35073

Find better location for __experimentalFetchRichUrlData function #32725

getdave opened this issue Jun 16, 2021 · 1 comment
Assignees
Labels
[Feature] Link Editing Link components (LinkControl, URLInput) and integrations (RichText link formatting)

Comments

@getdave
Copy link
Contributor

getdave commented Jun 16, 2021

What problem does this address?

In #32658 we created a WP-specific function that abstracts away the logic of fetching rich preview data for a given URL. This function is then added as a block editor setting called __experimentalFetchRichUrlData and then consumed by <LinkControl>.

Currently this function resides directly within the packages/editor/src/components/provider/use-block-editor-settings.js file. I'm not convinced this is the best location.

What is your proposed solution?

I would suggest this would be better suited to live within @wordpress/core-data. That would mean adding another API to core data but I feel it's valid.

@youknowriad I'd value your input on alternative suggestions.

@getdave getdave added the [Feature] Link Editing Link components (LinkControl, URLInput) and integrations (RichText link formatting) label Jun 16, 2021
@getdave getdave self-assigned this Jun 16, 2021
@getdave
Copy link
Contributor Author

getdave commented Oct 1, 2021

Closing this out as we removed the fetch function from this file.

@getdave getdave closed this as completed Oct 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Link Editing Link components (LinkControl, URLInput) and integrations (RichText link formatting)
Projects
None yet
Development

No branches or pull requests

1 participant