如何防止 Hyperledger Composer 应用程序加载 Bootstrap?

How to prevent Hyperledger Composer app from loading Bootstrap?

我想从我的 Hyperledger Composer 编译的项目中删除 Bootstrap 样式表。

我使用 yo hyperledger-composer 然后 npm start 编译。每当 src/index.htmlhttp://localhost:4200/ 得到服务时,Twitter Bootstrap <style> 标签就被插入到结束 </head> 标签之前。这是来源:

<head>
    <meta charset="utf-8">
    <title>My App</title>
    <base href="/">

    <style type="text/css">/*!
     * Bootstrap v3.3.7 (http://getbootstrap.com)
     * Copyright 2011-2016 Twitter, Inc.
     * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)

                ...
                [bootstrap.min.css is being inserted here, I don't know why]
                ...

        /*# sourceMappingURL=bootstrap.min.css.map */
    </style>

    <style type="text/css">/* You can add global styles to this file, and also import other style files */
    </style>
    <style></style>
    <style>{%BLOCK%}</style>
</head>

我应该在我的项目中的什么地方查找有问题的代码?我想完全删除这个 Bootstrap 标签。

我 grep 了 /src/ 目录,但是 "bootstrap" 没有找到任何结果(除了 .bootstrapModule(AppModule);.

在根目录中,作为"bootstrap": "^3.3.7",package.json中被列为依赖项。因此,我认为它正在从 node_modules/bootstrap/dist/bootstrap.min.css.

导入样式

没有 .angular-cli.json 文件。据我所知,我们没有使用 ng-bootstrap。这种样式注入来自哪里?

没关系,毕竟有一个.angular-cli.json文件。您可以从那里的脚本加载器中删除它。