Laravel Serve & NPM

Hi everyone,

I have been running into an issue when trying to import a site that I had previously worked on locally. I have been trying to figure out how I can configure my dev.nix to preform php artisan serve and npm run dev properly together. Though with no success.

On top of this even if I just serve the site with php artisan serve and then try to run npm run dev from the terminal it doesn’t have any apparent affect on the site. Same with just running npm run build.

Any ideas?

Hi @Tslol - when you try npm run dev, do you see a new port being exposed that you can use to preview your site?

Full-stack ports view

(Image taken from our blog post on this : Full-stack development in Project IDX)

1 Like


for automatic start for laravel serve i use this onStart in dev.nix file:

run-server = “php artisan serve”;