tango
tango copied to clipboard
WP-API path
In configuration you say:
api: the API's index, eg. http://localhost/wp-json (required)
But I'm having lots of 404 because in js/router.jsx you have:
template: <Archive endpoint={ config.api + '/wp/v2/posts?author_name=' + context.params[0] } title={ 'Author: ' + context.params[0] } />
https://github.com/kwight/tango/blob/master/js/router.jsx#L46
Removing those /wp/v2
clears the 404 errors but now I'm getting new ones:
Uncaught TypeError: Cannot read property 'join' of undefined @ public.js
Uncaught TypeError: Cannot read property '_currentElement' of null @ public.js
@juanbrujo which branch are you using of the API? This all assumes the develop
branch, and is working as expected in my own testing.
I used the master branch