Skip to content

Full Stack Application of Laravel, React with TypeScrpt, with Inertia v2.0, with Server side rendering and with spatie roles and permissions

Notifications You must be signed in to change notification settings

ag-php/laravel-react-inertia2-ssr

 
 

Repository files navigation

Laravel, React with Inertia v2 with TypeScript and SSR

Full Stack starter kit with Laravel, React with TypeScript, Inertia V2 with Server Side Rendering and with roles and permissions using Spatie Laravel Permission package.

To see every step how I created this project and deployed it on larareact.com with server side rendering check the following YouTube Tutorial

Demo

https://larareact.com

Admin User

Email: [email protected]
Password: password

Commenter User

Email: [email protected]
Password: password

Regular User

Email: [email protected]
Password: password

Local Setup

Tip

Make sure you have installed php, composer, node.js and the following commands are available in terminal. php, node, npm, composer.

  1. Clone the project
  2. Go to the project's root directory from terminal
  3. Copy .env.example into .env file (cp .env.example .env)
  4. Open and adjust your .env parameters
  5. Run composer install
  6. Run php artisan key:generate --ansi
  7. Execute migrations with seed data: php artisan migrate --seed
  8. Run npm install
  9. Run composer run dev for local development

Setup SSR

Follow the steps above including step 8, after which

  1. Open terminal and execute npm run build to build react assets
  2. Then start artisan server: php artisan serve
  3. Open another terminal and execute php artisan inertia:start-ssr to start server side rendering server

Deploy on Production

To see every step how to setup the project on production, assign domain to it and setup supervisor to start and monitor server side sendering server check the following YouTube tutorial.

About

Full Stack Application of Laravel, React with TypeScrpt, with Inertia v2.0, with Server side rendering and with spatie roles and permissions

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 50.9%
  • PHP 48.4%
  • Other 0.7%