Frontend Tips Episode 13

WP REST API - Add Posts From Frontend

In this episode we are going to be using WordPress REST API to add some new posts to our database with vanilla JavaScript.

As you will see this is very similar to what we did in this Next.js and Strapi series episode. This is because we used JWT authentication in both cases. So we will firstly authenticate ourselves to the WordPress installation using JWT, and then we will add some data to our posts with the token provided from JWT. This a super easy way to add authentication and allow your users to create content from the frontend of your site.

Wanna ask a question about video?

Like This Video?

Support it by sharing it ;)

© Watch And Learn,2024