Support v2 Taxonomy Routes - #126
Merged
Merged
Conversation
Mocha specs and Chai assertions benefit from a longer permitted line length, so that long "it" parameters and long chai assertion chains don't need to be artificially forced to wrap.
Many of these changes are adapted from work by @jasonphillips in his fork of the project -- full props to him for pioneering how to adapt the existing infrastructure to the new endpoints.
Closed
Slug searches are cumbersome; filtering was originally added in WP-API/WP-API#924 but has been removed again in the v2 betas (see WP-API/WP-API#924 for latest status) Integration tests demonstrate the best option we currently have, which is to search for the term then iterate through the responses from that search until you find a match.
Collaborator
Author
|
Querying by slug is "supported" inasmuch as 23ae892 adds a demonstration of how to do this by combining |
Again props to @jasonphillips for the initial implementation which I am adapting here (see below for commit link) jasonphillips@64ae6c4
Merged
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.
Support default taxonomy collections using v2 endpoints.
Many of these changes are adapted from work by @jasonphillips in his fork of the project -- full props to him for pioneering how to adapt the existing infrastructure to the new endpoints.
Tasks before PR can land:
/taxonomiesendpoint for available taxonomies/taxonomies/:taxonomyendpoint for taxonomy definition object/categories1st-party taxonomy term collection/categories/:idindividual category terms/tags1st-party taxonomy term collection/tags/:slugindividual category termsRelated work, to be executed separately: