Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to solve npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] [duplicate]

if I am trying to install a new library I getting this warning. And also that library is not getting installed

npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\watchpack-chokidar2\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})    
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\@angular\compiler-cli\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})    
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})     
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\webpack-dev-server\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})    
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\karma\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

"dependencies": {
        "@angular/animations": "^8.2.0",
        "@angular/common": "^8.2.0",
        "@angular/compiler": "^8.2.0",
        "@angular/core": "^8.2.0",
        "@angular/forms": "^8.2.0",
        "@angular/platform-browser": "^8.2.0",
        "@angular/platform-browser-dynamic": "^8.2.0",
        "@angular/router": "^8.2.0",
        "@ng-select/ng-select": "^3.6.2",
        "@swimlane/ngx-datatable": "^15.0.0",
        "angular2-draggable": "^2.3.2",
        "bootstrap": "^3.3.7",
        "core-js": "^2.5.4",
        "eonasdan-bootstrap-datetimepicker": "^4.17.47",
        "font-awesome": "^4.7.0",
        "jquery": "^3.3.1",
        "jspdf": "1.4.1",
        "jspdf-autotable": "^2.3.4",
        "material-icons": "^0.3.1",
        "moment": "^2.24.0",
        "mydatepicker": "^2.6.6",
        "ng2-date-picker": "^8.0.0",
        "ngx-bootstrap": "^4.3.0",
        "ngx-json-viewer": "^2.4.0",
        "ngx-toastr": "^11.3.3",
        "node-sass": "^4.14.1",
        "pretty-checkbox": "^3.0.3",
        "rxjs": "^6.5.1",
        "save": "^2.3.2",
        "sweetalert2": "^8.10.3",
        "underscore": "^1.9.1",
        "zone.js": "~0.9.1"
    },
    "devDependencies": {
        "@angular-devkit/build-angular": "^0.803.28",
        "@angular/cli": "^8.2.0",
        "@angular/compiler-cli": "^8.2.0",
        "@angular/language-service": "^8.2.0",
        "@types/datatables.net": "^1.10.14",
        "@types/jasmine": "~2.8.8",
        "@types/jasminewd2": "~2.0.3",
        "@types/jquery": "^3.3.29",
        "@types/node": "~8.9.4",
        "codelyzer": "^5.2.2",
        "jasmine-core": "~2.99.1",
        "jasmine-spec-reporter": "~4.2.1",
        "karma": "^5.1.0",
        "karma-chrome-launcher": "~2.2.0",
        "karma-coverage-istanbul-reporter": "~2.0.1",
        "karma-jasmine": "~1.1.2",
        "karma-jasmine-html-reporter": "^0.2.2",
        "protractor": "^7.0.0",
        "ts-node": "~7.0.0",
        "tslint": "~5.11.0",
        "typescript": "~3.5.0"
    }
like image 589
sharath Hanumanthaiah Avatar asked Jul 09 '20 07:07

sharath Hanumanthaiah


2 Answers

This shouldn't be an problem, it is a OSX mac dependency so only needs to be installed when using that operating system.

I am reading online you can force install with the following command but I shouldn't worry

npm install -f

You could also add it to "optionalDependencies": [] in your .package.json if you wanted to and do a fresh install, this should suppress the warnings, but you need to make sure you get the correct version.

like image 195
Dince12 Avatar answered Nov 17 '22 08:11

Dince12


It's optional. You don't need it unless you're developing on a Mac. Ignore it.

like image 4
Dennisch Avatar answered Nov 17 '22 07:11

Dennisch