Resolving Node-Sass Dependency Installation Issue in Laravel 5

Опубликовано: 03 Июнь 2026
на канале: Kirlled
186
1

Solution for problem trying to install dependencies of an old Laravel 5 project.

Encountering errors during 'npm install' related to the node-sass dependency is often a result of compatibility issues. In this video, I provide a solution by demonstrating how to upgrade the Laravel Mix package, addressing this problem effectively.

Error:
npm ERR! path .../node_modules/node-sass
npm ERR! command failed
npm ERR! command sh -c node scripts/build.js

Command for installing new version Lavel Mix:
npm install laravel-mix

Scripts:
"scripts": {
"development": "mix",
"watch": "mix watch",
"watch-poll": "mix watch -- --watch-options-poll=1000",
"hot": "mix watch --hot",
"production": "mix --production"
}