Error: ENOENT: no such file or directory, open '/app/node_modules/datatables.net/js/jquery.dataTable

Error: ENOENT: no such file or directory, open '/app/node_modules/datatables.net/js/jquery.dataTable

rh26rh26 Posts: 1Questions: 1Answers: 0

when i run yarn install --frozen-lockfile

i get-
92% additional asset processing scripts-webpack-plugin✖ 「wdm」: Error: ENOENT: no such file or directory, open '/app/node_modules/datatables.net/js/jquery.dataTables.js'

from the site i came to know that -
This is a stub types definition. datatables.net provides its own type definitions, so you do not need this installed.
i am maintaining the following package.json-

{
    "name": "@coreui/coreui-pro-angular-admin-template-starter",
    "version": "2.2.0",
    "description": "CoreUI Pro Angular 2+ Admin Template",
    "author": {
        "name": "Łukasz Holeczek",
        "url": "http://holeczek.pl",
        "github": "https://github.com/mrholek",
        "twitter": "https://twitter.com/lukaszholeczek"
    },
    "contributors": [
        {
            "name": "Andrzej Kopański",
            "url": "https://github.com/xidedix"
        }
    ],
    "homepage": "https://coreui.io/pro/angular",
    "copyright": "Copyright 2018 creativeLabs Łukasz Holeczek",
    "license": "https://coreui.io/pro/license/",
    "scripts": {
        "ng": "ng",
        "start": "ng serve",
        "build": "ng build --prod",
        "test": "ng test",
        "lint": "ng lint",
        "e2e": "ng e2e"
    },
    "private": true,
    "dependencies": {
        "@agm/core": "^1.0.0-beta.5",
        "@angular/animations": "^7.1.1",
        "@angular/cdk": "^7.3.7",
        "@angular/common": "^7.1.1",
        "@angular/compiler": "^7.1.1",
        "@angular/core": "^7.1.1",
        "@angular/forms": "^7.1.1",
        "@angular/http": "^7.1.1",
        "@angular/material": "^7.2.0",
        "@angular/platform-browser": "^7.1.1",
        "@angular/platform-browser-dynamic": "^7.1.1",
        "@angular/router": "^7.1.1",
        "@coreui/angular": "2.5.3",
        "@coreui/coreui-plugin-chartjs-custom-tooltips": "^1.2.0",
        "@coreui/coreui-pro": "^2.1.3",
        "@coreui/icons": "0.3.0",
        "@fortawesome/angular-fontawesome": "^0.3.0",
        "@fortawesome/fontawesome-svg-core": "^1.2.12",
        "@fortawesome/free-brands-svg-icons": "^5.6.3",
        "@fortawesome/free-solid-svg-icons": "^5.6.3",
        "@ng-bootstrap/ng-bootstrap": "^4.2.1",
        "@ng-select/ng-select": "^2.20.5",
        "@types/daterangepicker": "^3.0.1",
        "@types/file-saver": "^2.0.1",
        "angular-calendar": "^0.26.4",
        "angular-datatables": "^7.0.0",
        "angular2-datatable": "^0.6.0",
        "angular2-ladda": "^2.0.0",
        "angular2-text-mask": "^9.0.0",
        "angular2-toaster": "^7.0.0",
        "bootstrap": "^4.3.1",
        "chart.js": "2.7.3",
        "core-js": "^2.5.7",
        "datatables.net": "^1.10.19",
        "datatables.net-dt": "^1.10.19",
        "date-fns": "^1.29.0",
        "daterangepicker": "^3.0.5",
        "file-saver": "^2.0.2",
        "flag-icon-css": "3.2.1",
        "font-awesome": "^4.7.0",
        "jquery": "^3.4.1",
        "moment": "^2.24.0",
        "moment-ranges": "^0.8.12",
        "mutationobserver-shim": "^0.3.2",
        "net": "^1.0.2",
        "ng-select": "^1.0.1",
        "ng2-ace-editor": "^0.3.8",
        "ng2-charts": "^1.6.0",
        "ng2-dragula": "^1.5.0",
        "ng2-select2": "^1.0.0-beta.16",
        "ngx-audio-player": "^7.1.5",
        "ngx-bootstrap": "^4.2.0",
        "ngx-json-viewer": "^2.4.0",
        "ngx-material-timepicker": "3.3.1",
        "ngx-perfect-scrollbar": "^7.1.0",
        "ngx-quill": "^4.3.3",
        "popper": "^1.0.1",
        "quill": "^1.3.7",
        "repl": "^0.1.3",
        "rxjs": "^6.3.3",
        "rxjs-compat": "^6.3.3",
        "select2": "^4.0.8",
        "simple-line-icons": "^2.4.1",
        "sockjs-client": "1.3.0",
        "spinkit": "^1.2.5",
        "stompjs": "^2.3.3",
        "ts-helpers": "^1.1.2",
        "xlsx": "^0.15.2",
        "zone.js": "^0.8.26"
    },
    "devDependencies": {
        "@angular-devkit/build-angular": "^0.13.9",
        "@angular/cli": "^7.3.8",
        "@angular/compiler-cli": "^7.1.1",
        "@angular/language-service": "^7.1.1",
        "@types/datatables.net": "^1.10.17",
        "@types/jasmine": "^3.3.0",
        "@types/jasminewd2": "^2.0.6",
        "@types/jquery": "^3.3.31",
        "@types/node": "^10.12.11",
        "codelyzer": "^4.5.0",
        "jasmine-core": "^3.3.0",
        "jasmine-spec-reporter": "^4.2.1",
        "karma": "^4.1.0",
        "karma-chrome-launcher": "^2.2.0",
        "karma-coverage-istanbul-reporter": "^2.0.4",
        "karma-jasmine": "^2.0.1",
        "karma-jasmine-html-reporter": "^1.4.0",
        "node-sass": "^4.14.0",
        "protractor": "^5.4.1",
        "ts-node": "^7.0.1",
        "tslint": "^5.20.1",
        "typescript": "^3.1.6"
    },
    "engines": {
        "node": ">= 8.9.4",
        "npm": ">= 5.6.0"
    }
}

i am a beginner in angular , anyone knows how to solve this?

Answers

  • allanallan Posts: 63,262Questions: 1Answers: 10,424 Site admin

    "datatables.net": "^1.10.19",
    "datatables.net-dt": "^1.10.19",

    Should be installing DataTables 1.x. That being the case, I'm not sure why you would be getting the error you are. If you can create an example minimal repo or just StackBltiz to do so, I can take a look into it (although, note that DataTables 1.x is no longer supported and not receiving any updates).

    DataTables 2 would generate such an error if you try to reference jquery.dataTables.js. It was renamed to be dataTables.js in v2. See the upgrade docs.

    Allan

Sign In or Register to comment.