I've seen that in the isolated block editor's features there is this feature, "Re-routing of WordPress API requests". The thing is that I'd like to reroute the requests made by some of the components to match them with the backend. So far I just been successful with the root URL from apiFetch.createRootURLMiddleware.
I'll try to explain myself as best as possible with this example:
I insert the Image block with a URL:
Everything works just as expected, but the moment I click "Replace" or "Upload external image" the block breaks.
Another example, this time one that requires an API call (tag component):
Here, as my understanding it makes the API call with a path defined by the tags block, how it would be possible to reroute this path?
Hey folks!
I've seen that in the isolated block editor's features there is this feature, "Re-routing of WordPress API requests". The thing is that I'd like to reroute the requests made by some of the components to match them with the backend. So far I just been successful with the root URL from apiFetch.createRootURLMiddleware.
I'll try to explain myself as best as possible with this example:
I insert the Image block with a URL:
Everything works just as expected, but the moment I click "Replace" or "Upload external image" the block breaks.
Another example, this time one that requires an API call (tag component):
Here, as my understanding it makes the API call with a path defined by the tags block, how it would be possible to reroute this path?
Any help's more than welcomed,
Thanks a lot!