While installing lite-server it show vulnerabilities

919 Views Asked by At
  • [email protected] added 1 package from 2 contributors and audited 340 packages in 20.502s found 4 vulnerabilities (3 low, 1 high) run npm audit fix to fix them, or npm audit for details

After running 'npm audit fix' it shows

1 package is looking for funding run npm fund for details

fixed 0 of 4 vulnerabilities in 340 scanned packages 4 vulnerabilities required manual review and could not be updated

And an package-lock.json file has been created

1

There are 1 best solutions below

0
Dilip Rathod On

I found the fix for Ubuntu 18.04/20.04 after working for whole day. This should work for other Linux distros

1) Run following command for globally using lite-server
     sudo npm install lite-server -g
  1. Your package.json file should contain
     "devDependencies": {
    "lite-server": "^2.5.4"
     }

and scipt should look like

"scripts": {
    "start": "npm run lite",
    "test": "echo \"Error: no test specified\" && exit 1",
    "lite": "lite-server"
  },
3) For development mode run following
     sudo npm i lite-server --save-dev
  1. Local server could started using npm command
     npm start