-
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
Core Data uses hardcoded baseURL prefix for taxonomies and post types #35850
Conversation
Related: #35846 |
Size Change: +10 kB (+1%) Total Size: 1.08 MB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the update. It should be good to go now. I guess we should wait with merging until related changes land in WP core.
@gziolo As there is a conditional chaining here, this change is safe to merge now. It should fallback to |
I'd probably wait with merging this one until the core patches have been committed, so that this change can be tested with trunk. |
Is it possible to pull from the items response link instead? |
Nope, the links contains the full url. Which is not what we need in this context. |
Gotcha. Do we have the REST API base URL available at this point? |
I don't know a simple way of doing this. Maybe someone like @gziolo could answer this. |
The response of the endpoint |
Sorry, I think the question wasn't clear. In a javascript context, is there a simple way of getting the base url for the REST API, so http://www.example.com/wp-json? |
Description
Upstream change #53656 #54267
In the above upstream changes, the namespace is returned as part of the REST API response, this field is present in the response, otherwise default to wp/v2.
How has this been tested?
Screenshots
Types of changes
Checklist:
*.native.js
files for terms that need renaming or removal).Fixes #33420