Topic: I don't find .angular-cli.json in new version angular cli 6.0.8
Omar_AlQalei free asked 6 years ago
,how to add styles and scripts in VB code?.I Tried to add code between
{
\"$schema\": \"./node_modules/@angular/cli/lib/config/schema.json\",
\"version\": 1,
\"newProjectRoot\": \"projects\",
\"projects\": {
\"mdbs\": {
\"root\": \"\",
\"sourceRoot\": \"src\",
\"projectType\": \"application\",
\"prefix\": \"app\",
\"schematics\": {
\"@schematics/angular:component\": {
\"styleext\": \"scss\"
}
},
\"architect\": {
\"build\": {
\"builder\": \"@angular-devkit/build-angular:browser\",
\"options\": {
\"outputPath\": \"dist/mdbs\",
\"index\": \"src/index.html\",
\"main\": \"src/main.ts\",
\"polyfills\": \"src/polyfills.ts\",
\"tsConfig\": \"src/tsconfig.app.json\",
\"assets\": [
\"src/favicon.ico\",
\"src/assets\"
],
----------------------------------------------------------------------------------Here
\"styles\": [
\"../node_modules/font-awesome/scss/font-awesome.scss\",
\"../node_modules/angular-bootstrap-md/scss/bootstrap/bootstrap.scss\",
\"../node_modules/angular-bootstrap-md/scss/mdb-free.scss\",
\"styles.scss\"
],
\"scripts\": [
\"../node_modules/chart.js/dist/Chart.js\",
\"../node_modules/hammerjs/hammer.min.js\"
]
},
---------------------------------------------------------------------------------------------last
\"configurations\": {
\"production\": {
\"fileReplacements\": [
{
\"replace\": \"src/environments/environment.ts\",
\"with\": \"src/environments/environment.prod.ts\"
}
],
and after that doesn't support I don't know what is problem
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Status
Specification of the issue
- ForumUser: Free
- Premium support: No
- Technology: MDB Angular
- MDB Version: -
- Device: -
- Browser: -
- OS: -
- Provided sample code: No
- Provided link: No
Tags
Damian Gemza staff commented 6 years ago
Dear Omar_AlQalei, If you're using Angular 6, there's no .angular-cli.json file. Instead of it, there's angular.json file. In it, in styles and scripts arrays, you're not pointing from src directory, but from root directory. So remove " ../ " signs from your styles and scripts arrays and everything should be okay. Best Regards, DamianOmar_AlQalei free commented 6 years ago
Okay,thank you very much.Omar_AlQalei free commented 6 years ago
ERROR in multi ./node_modules/font-awesome/scss/font-awesome.scss ./node_modules/angular-bootstrap-md/scss/bootstrap/bootstrap.scss ./node_modules/angular-bootstrap-md/scss/mdb-free.scss ./styles.scss Module not found: Error: Can't resolve 'C:Usersomar-my-appstyles.scss' in 'C:Usersomar-my-app' i 「wdm」: Failed to compile.Omar_AlQalei free commented 6 years ago
After remove "../" signsDamian Gemza staff commented 6 years ago
styles.scss is located inside /src folder. So "./src/styles.scss"Omar_AlQalei free commented 6 years ago
91% additional asset processing scripts-webpack-plugin× 「wdm」: Error: ENOENT: no such file or directory, open 'C:Usersomar-node_moduleshammerjshammer.min.js' in cmd please create video to see how can I solve my problemOmar_AlQalei free commented 6 years ago
ERROR in No NgModule metadata found for 'AppModule'. i 「wdm」: Failed to compile.Dawid Adach pro commented 6 years ago
Dear Omar_AlQalei , regarding path you can clearly see that either is wrong (you are missing slashes: C:Usersomar-node_moduleshammerjshammer.min.js ) or it doesnt exist. Please verify the path to the file. Regarding No NgModule metadata found for ‘AppModule’. error, this is a known Angular issue, please navigate here for the solution : https://github.com/angular/angular-cli/issues/8798