相关疑难解决方法(0)

无法修改git bash Windows快捷方式

在Windows 7下,我想更改Git Bash Here shell扩展命令窗口的设置,例如宽度,高度和字体.但是当我这样做时,我收到错误"无法修改快捷方式".

我可以使用"以管理员身份运行..."在"开始"菜单中修改Git Bash的快捷方式,但这仅适用于从"开始"菜单打开的Bash窗口.它不适用于"Git Bash Here"shell扩展,右键单击上下文菜单中没有"以管理员身份运行..."选项.

你怎么做呢?

git bash windows-7

64
推荐指数
4
解决办法
4万
查看次数

如何加速Angular构建过程

我努力解决在TypeScript文件中的一些变化后每个构建需要超过20分钟的问题.我运行这个命令ng build --output-path=..\..\static\angularjs.

如果我在Microsoft PowerShell上运行它:它需要25 - 30秒.这是很多时间.

环境

  • Windows 10
  • 8 GB-Ram
  • PyCharm 64
  • MS PowerShell

有人知道,如何加快速度?

angular-cli angular

28
推荐指数
7
解决办法
4万
查看次数

如何调试缓慢的Ember CLI/Broccoli构建

我的Ember CLI项目目前需要8-9秒才能构建,我想了解原因.该项目不是那么大(app/包括hbs和scss的约180个文件).

这是我的brocfile:https://gist.github.com/samselikoff/874c90758bb2ce0bb210

但是,即使我将整个Brocfile注释掉并仅导出app变量,构建仍需要5-6秒.

我不太确定如何调试.这是我最慢的树日志:

建立成功 - 8874ms.

Slowest Trees                  | Total          
-------------------------------+----------------
TreeMerger (appAndDependencies)| 1286ms         
TreeMerger (vendor)            | 1275ms         
CompassCompiler                | 1204ms         
StaticCompiler                 | 1185ms         
TreeMerger (stylesAndVendor)   | 1151ms         
TreeMerger (allTrees)          | 706ms          
StaticCompiler                 | 625ms    
Run Code Online (Sandbox Code Playgroud)

ember-cli broccolijs

17
推荐指数
1
解决办法
3183
查看次数

为什么Angular 7框架在Google Chrome中的低CPU设备(Windows 10,2GB RAM,1GHz CPU)上速度极慢?

我创建了一个简单的项目,我已经安装了Bootstrap 4.但似乎加载页面需要8-10秒,CPU使用率为100%. 这是CPU使用率很高的桌面配置.

我通过AOT运行项目,其中ng服务--aot.在低CPU桌面上进行测试时,加载页面需要20-30秒.那么Angular是如何工作的,或者我们可以改进它并使用这种配置在低CPU桌面上加载一秒钟吗?

这是低CPU桌面上Angular的加载时序的屏幕截图.

即使在使用AOT之后,脚本编写部分也需要6-7秒来加载页面.这似乎很多.

具有8 GB RAM的台式机性能的屏幕截图.

由于CPU使用率很高,因此在低CPU设备上花费很长时间来加载页面.

下面是我的Angular JSON文件:

{
  "$schema": "./node_modules/@angular/cli/lib/config/schema.json",
  "version": 1,
  "newProjectRoot": "projects",
  "projects": {
    "testapp": {
      "root": "",
      "sourceRoot": "src",
      "projectType": "application",
      "prefix": "app",
      "schematics": {},
      "architect": {
        "build": {
          "builder": "@angular-devkit/build-angular:browser",
          "options": {
            "outputPath": "dist/testapp",
            "index": "src/index.html",
            "main": "src/main.ts",
            "polyfills": "src/polyfills.ts",
            "tsConfig": "src/tsconfig.app.json",
            "assets": [
              "src/favicon.ico",
              "src/assets"
            ],
            "styles": [
              "src/styles.css",
              "node_modules/bootstrap/dist/css/bootstrap.min.css"
            ],
            "scripts": [
              "node_modules/bootstrap/dist/js/bootstrap.min.js"
            ]
          },
          "configurations": {
            "production": {
              "fileReplacements": [
                {
                  "replace": "src/environments/environment.ts",
                  "with": …
Run Code Online (Sandbox Code Playgroud)

angular angular7

13
推荐指数
1
解决办法
3049
查看次数

本地开发中的Angular2慢速自动页面刷新 - Windows

我是新来angular2和之后的英雄从文档教程.我在使用angular2时遇到了相当慢的开发经验.angular2检测文件中的更改大约需要5秒,然后接下来需要30-40秒才能重新加载页面.

[0] 8:08:12 PM - File change detected. Starting incremental compilation...
[0] app/hero-detail.component.ts(2,8): error TS1192: Module '"app/app.component"' has no default export.
[0] 8:08:16 PM - Compilation complete. Watching for file changes.
[1][BS] File changed: app\app.component.js
[1] [BS] File changed: app\hero-detail.component.js
[1] [BS] File changed: app\main.js
[1] 16.02.07 20:08:39 304 GET /./index.html (Unknown - 8551ms)
[1] 16.02.07 20:08:45 304 GET /./index.html (Unknown - 1145ms)
[1] 16.02.07 20:08:45 304 GET /node_modules/es6-shim/es6-shim.min.js (Unknown - 384ms)
[1] 16.02.07 20:08:45 304 GET /node_modules/systemjs/dist/system-polyfills.js …
Run Code Online (Sandbox Code Playgroud)

javascript node.js typescript angular

11
推荐指数
1
解决办法
2341
查看次数

在windows上构建的ember-cli太慢了

我刚刚开始玩Ember和ember-cli.我创建了一个模板项目,并添加了几行js和一些来自Web Starter Kit的sass文件.我的项目增量构建时间几乎是15到25秒.我正在运行Windows 8.1,SSD,i5和12 GB RAM.

C:\Users\MyUser\Projects\ember\webapp>ember --version
version: 0.1.4
Could not find watchman, falling back to NodeWatcher for file system events
node: 0.10.29
npm: 2.1.10
Run Code Online (Sandbox Code Playgroud)

项目来源:https://github.com/mmrath/ember-webapp

我试过从索引,windows defender和从windows defender排除节点的项目目录.到目前为止没有任何工作.

我怎样才能缩短构建时间?

更新:以管理员身份运行命令提示符

C:\Users\MyUser\ember\webapp>ember serve
version: 0.1.4
Could not find watchman, falling back to NodeWatcher for file system events
Livereload server on port 35729
Serving on http://0.0.0.0:4200/

Build successful - 5632ms.

Slowest Trees                  | Total
-------------------------------+----------------
SassCompiler                   | 713ms
EsnextFilter                   | 622ms
ES6Concatenator                | 530ms
EsnextFilter                   | 413ms …
Run Code Online (Sandbox Code Playgroud)

ember.js ember-cli

5
推荐指数
1
解决办法
1349
查看次数

两台相同型号的笔记本电脑之间的 Angular 编译器速度很慢

我和同事正试图弄清楚为什么编译时间不同。我们拥有完全相同的戴尔笔记本电脑 7030 型号、相同的固态硬盘、相同的硬盘、相同的内存和规格。我们的任务管理器流程看起来很相似。

公司订购相同型号的计算机。

我们正在从 Angular Git Repository 下载,带有配置和包 json,具有相同的节点大小内存。

问题是,我们的笔记本电脑之间的初始构建是 2 分钟,而 8 分钟。

当我们在同一个文件中编辑一个单词时,他只需要 5 秒重新编译,我需要 20 秒。只有在同一台计算机上运行的程序才是 Angular 命令 ng serve。

有没有人有解决这个问题的想法,编译时间很慢?

有什么我可以在我的工作站中改变编译速度的东西吗?

为所有同事尝试了解决方案,仍然很慢

  • 我们有相同的 Node.js 版本
  • 在公司项目 Git Repo 中从 Angular 8 更新到 10
  • 试过了 npm cache clear
  • 尝试卸载和重新安装 Angular 和 Nodejs
  • 来自 Windows 的磁盘扫描程序不会在 SSD 驱动器上显示错误
  • 将 package-lock.json 与同事进行比较,它们完全相同,在源代码控制差异中进行比较
  • 在 Angular Git 文件夹上打开 Windows Defender 排除

资源:

Angular 编译很慢

如何加快 Angular 构建过程

更新:

刚刚注意到我的笔记本电脑在 style.scss 文件上真的停顿在 48%

sass node.js typescript angular angular10

5
推荐指数
1
解决办法
806
查看次数