angular.json 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137
  1. {
  2. "$schema": "./node_modules/@angular/cli/lib/config/schema.json",
  3. "cli": {
  4. "analytics": false
  5. },
  6. "version": 1,
  7. "newProjectRoot": "projects",
  8. "projects": {
  9. "h5-app": {
  10. "projectType": "application",
  11. "schematics": {
  12. "@schematics/angular:component": {
  13. "style": "less"
  14. },
  15. "@schematics/angular:application": {
  16. "strict": true
  17. }
  18. },
  19. "root": "",
  20. "sourceRoot": "src",
  21. "prefix": "app",
  22. "architect": {
  23. "build": {
  24. "builder": "@angular-devkit/build-angular:browser",
  25. "options": {
  26. "outputPath": "dist/h5-app",
  27. "index": "src/index.html",
  28. "main": "src/main.ts",
  29. "polyfills": "src/polyfills.ts",
  30. "tsConfig": "tsconfig.app.json",
  31. "aot": true,
  32. "assets": [
  33. "src/favicon.ico",
  34. "src/assets"
  35. ],
  36. "styles": [
  37. "node_modules/ng-zorro-antd-mobile/src/ng-zorro-antd-mobile.min.css",
  38. "src/styles.less"
  39. ],
  40. "scripts": []
  41. },
  42. "configurations": {
  43. "production": {
  44. "fileReplacements": [
  45. {
  46. "replace": "src/environments/environment.ts",
  47. "with": "src/environments/environment.prod.ts"
  48. }
  49. ],
  50. "optimization": true,
  51. "outputHashing": "all",
  52. "sourceMap": false,
  53. "namedChunks": false,
  54. "extractLicenses": true,
  55. "vendorChunk": false,
  56. "buildOptimizer": true,
  57. "budgets": [
  58. {
  59. "type": "initial",
  60. "maximumWarning": "500kb",
  61. "maximumError": "1mb"
  62. },
  63. {
  64. "type": "anyComponentStyle",
  65. "maximumWarning": "2kb",
  66. "maximumError": "4kb"
  67. }
  68. ]
  69. }
  70. }
  71. },
  72. "serve": {
  73. "builder": "@angular-devkit/build-angular:dev-server",
  74. "options": {
  75. "browserTarget": "h5-app:build",
  76. "proxyConfig": "src/proxy.config.json"
  77. },
  78. "configurations": {
  79. "production": {
  80. "browserTarget": "h5-app:build:production"
  81. }
  82. }
  83. },
  84. "extract-i18n": {
  85. "builder": "@angular-devkit/build-angular:extract-i18n",
  86. "options": {
  87. "browserTarget": "h5-app:build"
  88. }
  89. },
  90. "test": {
  91. "builder": "@angular-devkit/build-angular:karma",
  92. "options": {
  93. "main": "src/test.ts",
  94. "polyfills": "src/polyfills.ts",
  95. "tsConfig": "tsconfig.spec.json",
  96. "karmaConfig": "karma.conf.js",
  97. "assets": [
  98. "src/favicon.ico",
  99. "src/assets"
  100. ],
  101. "styles": [
  102. "node_modules/ng-zorro-antd-mobile/src/ng-zorro-antd-mobile.min.css",
  103. "src/styles.less"
  104. ],
  105. "scripts": []
  106. }
  107. },
  108. "lint": {
  109. "builder": "@angular-devkit/build-angular:tslint",
  110. "options": {
  111. "tsConfig": [
  112. "tsconfig.app.json",
  113. "tsconfig.spec.json",
  114. "e2e/tsconfig.json"
  115. ],
  116. "exclude": [
  117. "**/node_modules/**"
  118. ]
  119. }
  120. },
  121. "e2e": {
  122. "builder": "@angular-devkit/build-angular:protractor",
  123. "options": {
  124. "protractorConfig": "e2e/protractor.conf.js",
  125. "devServerTarget": "h5-app:serve"
  126. },
  127. "configurations": {
  128. "production": {
  129. "devServerTarget": "h5-app:serve:production"
  130. }
  131. }
  132. }
  133. }
  134. }
  135. },
  136. "defaultProject": "h5-app"
  137. }