WP-API / docs

The content for developer.wordpress.org/rest-api
https://developer.wordpress.org/rest-api
110 stars 620 forks source link

Inline code formatting is broken #150

Open ghost opened 1 year ago

ghost commented 1 year ago

The inline code formatting is broken when it contains a URL: https://developer.wordpress.org/rest-api/extending-the-rest-api/routes-and-endpoints/

It is rendered fine in the GitHub preview: https://github.com/WP-API/docs/blob/master/extending-the-rest-api/routes-and-endpoints.md

flexseth commented 6 months ago

This probably needs to be explicit <code> - opening and closing where necessary.

Where is this issue in the page?

The REST API provides us a way to match URIs to various resources in our WordPress install. By default, if you have pretty permalinks enabled, the WordPress REST API “lives” at /wp-json/. At our WordPress site https://ourawesomesite.com`, we can access the REST API's index by making a...... Link to highlight

https://ourawesomesite.com/wp-json`. The index route for the API is/which is why

https://ourawesomesite.com/wp-json/books`. However, this is not a good practice as we would end up polluting potential routes for the API. What if another plugin we wanted to register a books route as well? We would be in big trouble in that case, as the two routes would conflict with each other and only one could be used. The fourth parameter to

(I believe this has to do with links being determined to be HTML) See this hint on SO

Will take a look at this during the docs office hours tomorrow.