akveo / ngx-admin

Customizable admin dashboard template based on Angular 10+
https://akveo.github.io/ngx-admin/
MIT License
25.19k stars 7.94k forks source link

ng serve not working after updates #5781

Closed RoWEN-FCUB closed 3 years ago

RoWEN-FCUB commented 3 years ago

I've upgraded my app modules to the last version of each, and now when I do ng serve I get the error: "Schema validation failed with the following errors: Data path "" should have required property 'main'."

package.json give me the warning: "Problems loading reference 'https://json.schemastore.org/package': Unable to load schema from 'https://json.schemastore." { "name": "ngx-admin", "version": "4.0.1", "license": "MIT", "repository": { "type": "git", "url": "git+https://github.com/akveo/ngx-admin.git" }, "bugs": { "url": "https://github.com/akveo/ngx-admin/issues" }, "scripts": { "ng": "ng", "conventional-changelog": "conventional-changelog", "start": "ng serve", "build": "ng build", "build:prod": "npm run build -- --prod --aot", "test": "ng test", "test:coverage": "rimraf coverage && npm run test -- --code-coverage", "lint": "ng lint", "lint:fix": "ng lint ngx-admin-demo --fix", "lint:styles": "stylelint ./src/*/.scss", "lint:ci": "npm run lint && npm run lint:styles", "pree2e": "webdriver-manager update --standalone false --gecko false", "e2e": "ng e2e", "docs": "compodoc -p src/tsconfig.app.json -d docs", "docs:serve": "compodoc -p src/tsconfig.app.json -d docs -s", "prepush": "npm run lint:ci", "release:changelog": "npm run conventional-changelog -- -p angular -i CHANGELOG.md -s" }, "dependencies": { "@agm/core": "^1.1.0", "@akveo/ng2-completer": "^9.0.1", "@angular/animations": "^10.1.4", "@angular/cdk": "^10.2.3", "@angular/common": "^10.1.4", "@angular/compiler": "^10.1.4", "@angular/core": "^10.1.4", "@angular/forms": "^10.1.4", "@angular/localize": "^10.1.4", "@angular/platform-browser": "^10.1.4", "@angular/platform-browser-dynamic": "^10.1.4", "@angular/router": "^10.1.4", "@fortawesome/angular-fontawesome": "^0.7.0", "@fortawesome/fontawesome-svg-core": "^1.2.32", "@fortawesome/free-solid-svg-icons": "^5.15.1", "@nebular/auth": "6.2.1", "@nebular/eva-icons": "6.2.1", "@nebular/security": "6.2.1", "@nebular/theme": "6.2.1", "@ng-bootstrap/ng-bootstrap": "^7.0.0", "@ngtools/webpack": "^10.1.4", "@swimlane/ngx-charts": "^16.0.0", "angular2-chartjs": "0.5.1", "bootstrap": "4.5.2", "chart.js": "^2.9.3", "ckeditor": "4.7.3", "classlist.js": "1.1.20150312", "core-js": "^3.6.5", "echarts": "^4.9.0", "eva-icons": "^1.1.3", "html-to-pdfmake": "^2.0.10", "intl": "1.2.5", "ionicons": "5.1.2", "jquery": "^3.5.1", "leaflet": "1.7.1", "moment": "^2.29.0", "ncu": "^0.2.1", "nebular-icons": "1.1.0", "ng-number-picker": "^1.1.9", "ng-pick-datetime": "^7.0.0", "ng2-ckeditor": "^1.2.9", "ng2-smart-table": "^1.6.0", "ngx-echarts": "^5.1.2", "ngx-export-as": "^1.5.0", "ngx-material-timepicker": "^5.5.3", "ngx-pagination": "^5.0.0", "node-sass": "^4.14.1", "normalize.css": "8.0.1", "pace-js": "1.0.2", "pdfmake": "^0.1.68", "popper.js": "^1.15.0", "roboto-fontface": "0.10.0", "rxjs": "6.6.3", "rxjs-compat": "6.6.3", "socicon": "3.0.5", "style-loader": "^1.3.0", "sweetalert2": "^10.3.5", "tinymce": "5.5.1", "tslib": "^2.0.1", "typeface-exo": "0.0.61", "web-animations-js": "^2.3.2", "zone.js": "~0.11.1" }, "devDependencies": { "@angular-devkit/build-angular": "^0.1001.4", "@angular/cli": "^10.1.4", "@angular/compiler-cli": "^10.1.4", "@angular/language-service": "10.1.4", "@compodoc/compodoc": "^1.1.11", "@fortawesome/fontawesome-free": "^5.15.1", "@types/d3-color": "2.0.0", "@types/googlemaps": "^3.39.13", "@types/jasmine": "3.5.14", "@types/jasminewd2": "2.0.8", "@types/leaflet": "1.5.17", "@types/node": "^14.11.2", "codelyzer": "^6.0.1", "conventional-changelog-cli": "2.1.0", "husky": "4.3.0", "jasmine-core": "3.6.0", "jasmine-spec-reporter": "6.0.0", "karma": "5.2.3", "karma-chrome-launcher": "3.1.0", "karma-cli": "2.0.0", "karma-coverage-istanbul-reporter": "3.0.3", "karma-jasmine": "4.0.1", "karma-jasmine-html-reporter": "1.5.4", "npm-run-all": "4.1.5", "protractor": "7.0.0", "rimraf": "3.0.2", "stylelint": "13.7.2", "ts-node": "9.0.0", "tslint": "^5.20.1", "tslint-language-service": "^0.9.9", "typescript": "4.0.3" } }

angular.json { "$schema": "./node_modules/@angular/cli/lib/config/schema.json", "version": 1, "newProjectRoot": "projects", "projects": { "ngx-admin-demo": { "root": "", "sourceRoot": "src", "projectType": "application", "architect": { "build": { "builder": "@angular-devkit/build-angular:browser", "preserveSymlinks": true, "rebaseRootRelativeCssUrls": true, "outputPath": "dist", "index": "src/index.html", "main": "src/main.ts", "tsConfig": "src/tsconfig.app.json", "polyfills": "src/polyfills.ts", "assets": [ "src/assets", "src/favicon.ico", "src/favicon.png" ], "styles": [ "src/app/@theme/styles/styles.scss", {"input":"node_modules/bootstrap/dist/css/bootstrap.css"}, "node_modules/typeface-exo/index.css", "node_modules/roboto-fontface/css/roboto/roboto-fontface.css", "node_modules/ionicons/css/ionicons.css", "node_modules/socicon/css/socicon.css", "node_modules/nebular-icons/scss/nebular-icons.scss", "node_modules/pace-js/templates/pace-theme-flash.tmpl.css",
"node_modules/@fortawesome/fontawesome-free/css/all.css" ], "scripts": [ "node_modules/pace-js/pace.min.js", "node_modules/@fortawesome/fontawesome-free/js/all.js" ], "configurations": { "production": { "optimization": true, "outputHashing": "all", "sourceMap": false, "extractCss": true, "namedChunks": false, "aot": true, "extractLicenses": true, "vendorChunk": false, "buildOptimizer": true, "fileReplacements": [ { "replace": "src/environments/environment.ts", "with": "src/environments/environment.prod.ts" } ] } } }, "serve": { "builder": "@angular-devkit/build-angular:dev-server", "options": { "browserTarget": "ngx-admin-demo:build" }, "configurations": { "production": { "browserTarget": "ngx-admin-demo:build:production" } } }, "extract-i18n": { "builder": "@angular-devkit/build-angular:extract-i18n", "options": { "browserTarget": "ngx-admin-demo:build" } }, "test": { "builder": "@angular-devkit/build-angular:karma", "options": { "main": "src/test.ts", "karmaConfig": "./karma.conf.js", "polyfills": "src/polyfills.ts", "tsConfig": "src/tsconfig.spec.json", "scripts": [ "node_modules/pace-js/pace.min.js", "node_modules/@fortawesome/fontawesome-free/js/all.js" ], "styles": [ "node_modules/bootstrap/dist/css/bootstrap.css", "node_modules/typeface-exo/index.css", "node_modules/roboto-fontface/css/roboto/roboto-fontface.css", "node_modules/ionicons/scss/ionicons.scss", "node_modules/socicon/css/socicon.css", "node_modules/nebular-icons/scss/nebular-icons.scss", "node_modules/pace-js/templates/pace-theme-flash.tmpl.css", "src/app/@theme/styles/styles.scss", "node_modules/@fortawesome/fontawesome-free/css/all.css" ], "assets": [ "src/assets", "src/favicon.ico", "src/favicon.png" ] } }, "lint": { "builder": "@angular-devkit/build-angular:tslint", "options": { "tsConfig": [ "src/tsconfig.app.json", "src/tsconfig.spec.json" ], "typeCheck": true, "exclude": [] } } } }, "ngx-admin-demo-e2e": { "root": "", "sourceRoot": "", "projectType": "application", "architect": { "e2e": { "builder": "@angular-devkit/build-angular:protractor", "options": { "protractorConfig": "./protractor.conf.js", "devServerTarget": "ngx-admin-demo:serve" } }, "lint": { "builder": "@angular-devkit/build-angular:tslint", "options": { "tsConfig": [ "e2e/tsconfig.e2e.json" ], "exclude": [] } } } } }, "defaultProject": "ngx-admin-demo", "schematics": { "@schematics/angular:component": { "styleext": "scss" }, "@schematics/angular:directive": {} } }

I deleted the node_modules folder and did npm install but the error persist. Thanks for any help.

RoWEN-FCUB commented 3 years ago

I found the problem, was a missplaced { in the angular.json. Clossing the issue.