日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

Angular 项目工程文件结构介绍

發布時間:2023/12/19 编程问答 26 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Angular 项目工程文件结构介绍 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

https://angular.io/guide/file-structure

You develop applications in the context of an Angular workspace.

Angular 應用開發人員在 Angular workspace(工作空間)的上下文里進行應用開發。

A workspace contains the files for one or more projects.

一個工作空間包含若干文件,這些文件屬于一個或多個 projects.

A project is the set of files that comprise a standalone application or a shareable library.

所謂 project,就是一系列文件的集合,組成了一個能夠單獨運行的應用,或是一個可重用的庫。

ng new 創建一個新的 workspace.

Workspace 里所有 project,共享同一個 CLI configuration context.

All projects within a workspace share a CLI configuration context.

Workspace 根目錄下的 angular.json 文件,提供了 workspace 級別和 project 特定的配置信息,用于 Angular CLI build 和 development 工具使用。

A file named angular.json at the root level of an Angular workspace provides workspace-wide and project-specific configuration defaults for build and development tools provided by the Angular CLI.

Path values given in the configuration are relative to the root workspace folder.

angular.json 里的 Path value 均為基于 root workspace 的相對路徑。

  • package-lock.json: Provides version information for all packages installed into node_modules by the npm client. See npm documentation for details. If you use the yarn client, this file will be yarn.lock instead.

包含使用 npm 客戶端安裝到 node_modules 里的所有包的版本信息。

  • node_modules/:Provides npm packages to the entire workspace. Workspace-wide node_modules dependencies are visible to all projects.

Workspace 級別的依賴包,對所有 projects 均可見。

  • tsconfig.json:TypeScript 相關配置信息。

For a single-application workspace, the src/ subfolder of the workspace contains the source files (application logic, data, and assets) for the root application. For a multi-project workspace, additional projects in the projects/ folder contain a project-name/src/ subfolder with the same structure.

SAP Spartacus 屬于 multi-project workspace,project 文件夾下有 sub 文件夾。

  • app:Contains the component files in which your application logic and data are defined.

更多Jerry的原創文章,盡在:“汪子熙”:

總結

以上是生活随笔為你收集整理的Angular 项目工程文件结构介绍的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。