1.0.8 • Published 3 years ago

create-react-app-for-wp v1.0.8

Weekly downloads
12
License
ISC
Repository
github
Last release
3 years ago

create-react-app-for-wp

Create a react app that can be used in WordPress Theme & Plugins.

Installation

$ npx create-react-app-for-wp
  • This will install the app in your current directory. So, make sure you are in the right directory where you want to install React.
  • Write your React components in the src/components folder. Entry point is src/components/App.js.
  • Now run npm run build - It will continuously watch your code and produce a single javascript file called build/index.js.
  • Enqueue this build/index.js file in your theme or plugin using wp_enqueue_script.
  • Make sure you have a <div id="react-js-in-wp"></div> in your webpage. React will be rendered in this div.
  • After you have finished building your application, run npm run prod to make a minified production build.
1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago