我有一个使用 cli 命令创建的应用程序。我的 angular-cli.json 文件看起来像这样
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"project": {
"name": "lienholder"
},
"apps": [
{
"root": "src",
"outDir": "dist",
"assets": [
"assets",
"favicon.ico"
],
"index": "index.html",
"main": "main.ts",
"polyfills": "polyfills.ts",
"test": "test.ts",
"tsconfig": "tsconfig.app.json",
"testTsconfig": "tsconfig.spec.json",
"prefix": "app",
"styles": [
"../node_modules/bootstrap/dist/css/bootstrap.min.css",
"style.css"
],
"scripts": [],
"environmentSource": "environments/environment.ts",
"environments": {
"dev": "environments/environment.ts",
"prod": "environments/environment.prod.ts"
}
}
],
"e2e": {
"protractor": {
"config": "./protractor.conf.js"
}
},
"lint": [
{
"project": "src/tsconfig.app.json",
"exclude": "**/node_modules/**"
},
{
"project": "src/tsconfig.spec.json",
"exclude": "**/node_modules/**"
},
{
"project": "e2e/tsconfig.e2e.json",
"exclude": "**/node_modules/**"
}
],
"test": {
"karma": {
"config": "./karma.conf.js"
}
},
"defaults": {
"styleExt": "css",
"component": {}
}
}
现在当我使用命令构建应用程序时
ng build --target=development --environment=dev
它创建一个 dist 文件夹 i,其中包含以下所有文件
dist
-assests
images
image1
image2
style.css
-favicon.ico
-glyphicons-halflings-regular.448c34a56d699c29117a.woff2
-glyphicons-halflings-regular.448c34a56d699c29117a.svg
-glyphicons-halflings-regular.448c34a56d699c29117a.ttf
-glyphicons-halflings-regular.448c34a56d699c29117a.eot
-glyphicons-halflings-regular.448c34a56d699c29117a.woff
-index.html
-inline.bundle.js
-inline.bundle.js.map
-main.bundle.js
-main.bundle.js.map
-polyfills.bundle.js
-polyfills.bundle.js.map
-styles.bundle.js
-styles.bundle.js.map
-vendor.bundle.js
-vendor.bundle.js.map
现在,我想要的是,我不想将所有字形图标放在根目录上,而是想将所有字形文件放在一个文件夹中,如下所示
glyphicons-folder
-glyphicons-halflings-regular.448c34a56d699c29117a.woff2
-glyphicons-halflings-regular.448c34a56d699c29117a.svg
-glyphicons-halflings-regular.448c34a56d699c29117a.ttf
-glyphicons-halflings-regular.448c34a56d699c29117a.eot
-glyphicons-halflings-regular.448c34a56d699c29117a.woff
我怎样才能做到这一点?
UPDATE
这就是文件夹放置在 node_modules 文件夹中的方式