我有一个角组件,作为其他组件的正面。这是使用ComponentFactoryResolver实现的。当我将管道引入其中一个生成的组件时,我的单元测试开始以一种奇怪的方式失败。
,我希望有人能解释为什么会这样失败?
Failed: NG0302: The pipe 'displayValue' could not be found!. Find more at https://angular.io/errors/NG0302
error properties: Object({ code: '302' })
Erro
我使用的角度材料谷歌地图组件,以集成地图到一个离子/电容应用程序。
在开发应用程序时,映射功能非常好。当我试图为实现Google的组件运行测试文件时,我会得到以下错误:
Failed: Namespace google not found, cannot construct embedded google map. Please install the Google Maps JavaScript API: https://developers.google.com/maps/documentation/javascript/tutorial#Loading_the_Maps_API
Err
这个奇怪的错误,我不记得看到了前常春藤,已经弹出了一个新的应用程序创建与最新的角度9 CLI。看上去可能是艾薇身上的虫子?任何关于如何修复的想法都将不胜感激。
ng测试的误差结果
Error: This constructor was not compatible with Dependency Injection.
at Module.ɵɵinvalidFactory (http://localhost:9876/_karma_webpack_/node_modules/@angular/core/__ivy_ngcc__/fesm5/core.js:14150:1)
at
我不清楚角渲染器到底是什么。根据一些消息来源,这是part of compiler that compiles the templates to JS code。
据其他一些消息来源说:
First, there was the original compiler (which was not referred to as a view engine).
Then, for version 4, the team introduced the view engine, referred to as "renderer2."
Ivy is next in line.
我从上面
我已经查看了有关此错误的问题,但尚未找到解决方案。
我有一个突出显示指令,并且我接受一个输入index。当我在使用它的模块中声明它时,这个指令就起作用了。但我想在几个模块中使用它,所以我删除了声明,并将其放在导入错误的根模块中。
Error: Template parse errors:
Can't bind to 'index' since it isn't a known property of 'div'. ("
<div class="read row"
我试图在我的项目中添加一个常规类,但我得到了
zone.js:917 Uncaught Error: Unexpected value 'Tools' declared by the module 'AppModule'.
Please add a @Pipe/@Directive/@Component annotation.
它只是一个常规的类型记录类,我希望能够在我的项目中使用
它不是指令,也不是管道,也不是组件。
export class Tools
{
pascalCase(text:string)
{
return t
我有一个angular 8项目,当我启用angular Ivy时,它在编译时会失败。当我检查其他人提供的解决方案并更新到angular 8.1.0(从8.0.3),但问题仍然存在,并不断给我以下错误:
D:\Users\Backup>ng build shared
Building Angular Package
Building entry point 'shared'
Compiling TypeScript sources through ngc
BUILD ERROR
node_modules/@angular/common/common.d.ts(115,22
我正在学习这篇教程。
但是我一直收到这个错误:
EXCEPTION: No Directive annotation found on CoursesComponent
我的app.components.ts看起来像这样
import {Component} from 'angular2/core';
import {CoursesComponent} from './courses.component';
@Component({
selector: 'my-app',
template: '<h1>He
我编写了一个实现来从API调用中获取数据。但是,在测试功能时,甚至在编写任何有意义的测试用例之前,我都会得到以下错误:
TypeError: Cannot read property 'subscribe' of undefined
at DataComponent.ngOnInit (http://localhost:9876/_karma_webpack_/webpack:/src/app/dashboard/job/job.component.ts:48:10)
at callHook (http://localhost:9876/_karma_webpa
我一直在做一个应用程序的单元测试,我遇到了一个失败,我似乎找不到任何地方。我现在用的是角9的标志性5。茉莉花说:
StatisticsPage > should create
Failed: parentContexts.onChildOutletCreated is not a function
at <Jasmine>
at new IonRouterOutlet (http://localhost:9876/_karma_webpack_/node_modules/@ionic/angular/__ivy_ngcc__/fesm2015/ionic-an
我正在学习关于角5的在线教程,使用Visual代码和最新的角版本:
角CLI: 7.0.6
节点: 10.7.0
角度: 7.0.4,
VS代码不会引发任何错误,但是当我在inputText中添加(InputText)=“inputText”时,浏览器控制台会显示一个错误:
错误:模板解析错误:
Can't bind to 'ngModule' since it isn't a known property of 'input'. ("<input type="text" [ER