Developing Themes with React/Angular

First of all like Fayaz had said questions with multiple questions are not the best way to ask something on this platform.

Ok, let me try to answer your questions.

(Disclaimer: I’m not an react expert. So please don`t hang me if i tell something stupid.)

Question 1:

No you need not Node.js but npm cloud be very helpful in the JavaScript development process. The easiest way to install npm is to install node.js.

Question 2:

If you create a normal theme (style.css + index.php) and then bundled your new frontend code with that theme, i think this should work.

Question 3:

For the WordPress respositroy => no perhaps you can upload as “experimental” theme
For themeforest/wrapbootstrap => maybe I don`t know => it the best you ask the support of this plattforms

You are not the first one with the idea to separate the frontend code from WordPress and use the REST Api as content supplier. In 2017 the developer Kelly Dwan built the react-base single page theme called “Foxhound“. Maybe it is helpfully foryou.

I think the most important problem is that most of the frontend plugins or widgets will not work with your theme. Because the wordpress theme function will not be trigger.

Usefull links:

Foxhound Is the First REST API Powered Theme on WordPress.org – wptavern.com

Foxhound – github.com

Leave a Comment