我意识到每次运行ng服务时,我都不能再使用命令提示符了.这意味着 - 它不允许新命令.是什么原因,我该如何解决?这意味着,假设我想从CLI创建新的服务/组件而不是写它,它不允许新的命令它写道:webpack:编译成功.然后你无法真正键入新命令
谢谢
我刚刚安装了节点 12。我错误地安装了所有 python 东西,现在很难摆脱它。这就像一个恶意软件...
我尝试从环境变量、程序和功能中删除
npm -g uninstall node-gyp
Run Code Online (Sandbox Code Playgroud)
但它仍然作为恶意软件保留在我的开始菜单中,只有好的防病毒软件才能删除......

我缺少什么?为了摆脱这个恶意软件我还应该做什么..?我无法使用 Angular cli
谢谢。
我有一个表格,其中一列显示一个链接,点击它会打开一个新页面。要显示我正在使用的特定链接:
`cellRenderer: "motorBikeType"`, under `this.columnDefs = [...`
Run Code Online (Sandbox Code Playgroud)
为了在列中显示不同的摩托车类型,我使用 , 中的agInit函数(正如我之前在此处回答的那样)motorBikeType component通过params.data.motorBikeType
这工作正常。表格显示正确,我得到了每种类型摩托车的一个很好的链接。
当我单击链接时,问题就开始了。在打开的新页面中(几乎是motorBikeType组件,params.node.data.motorBikeType不再可用。
如果我 console.log 它 - 我会在控制台中看到它。但它不会让我绑定到 html 视图motorBikeType
我什至尝试在类中创建一个局部变量,例如:
export class motorBikeType {
...
motorbike: any;
agInit(params: any): void {
this.params = params;
this.motorbike = params.data.motorBikeType;
}
}
Run Code Online (Sandbox Code Playgroud)
然后在 html 视图中:
<a *ngIf="... >{{params.data.motorBikeType}}</a>
<p *ngIf="...>{{params.data.motorBikeType}}</a>
Run Code Online (Sandbox Code Playgroud)
它只会在表格列中显示 link ,但是一旦它重定向到页面(我正在使用路由器),它就不会显示具有绑定值的段落。
我也试过里面ngOnInit() {...做this.motorbike = this.params.data.motorBikeType;
但它在视图中仍然没有约束力。
我需要的是params.data.motorBikeType在视图中显示。
像<p>{{params.data.motorBikeType}}或<p>{{motorbike}}</p>
谢谢。
I have an array of links that each element is an object that contain few strings - a link, description and category. I have different components that display the links, and I want in each component to display only the links of its category. So I want to filter the array by the category.
I have a mock-up array with all the links.
I try to filter the array of objects without a pipe. The reason why: https://angular.io/guide/pipes#appendix-no-filterpipe-or-orderbypipe
Apparently the …
我的网站有问题。它是用Angular 4编写的。
问题出在这里:我只能使用以下链接:www.mywebsite.com(例如,如果使用):www.mywebsite.com/page、www.mywebsite.com/page1这会给我一个错误。意思是,如果我先去mywebsite.com然后单击链接,那么它将显示正确的页面。但是,如果我将浏览器放入mywebsite.com/page,那么它将显示错误页面。
我正在使用标准的角度路由器并将其托管在GoDaddy上。知道为什么会这样吗?