-
check_circle_outlineMódulo 1 | 2 clases
Introducción
expand_more -
check_circle_outlineMódulo 2 | 8 clases
Typescript
expand_more -
check_circle_outlineMódulo 3 | 9 clases
Angular 2
expand_more-
done_all
Clase 1
11.- Conociendo Angular 2
-
done_all
Clase 2
12.- Crear app Angular 2
-
done_all
Clase 3
13.- Primer componente (export e import)
-
done_all
Clase 4
14.- Directivas de atributos
-
done_all
Clase 5
15.- Property binding
-
done_all
Clase 6
16.- Eventos
-
done_all
Clase 7
17.- Two way data binding
-
done_all
Clase 8
18.- Estilos en las vistas
-
done_all
Clase 9
19.- Servicios
-
-
check_circle_outlineMódulo 4 | 3 clases
Iniciando la app
expand_more -
check_circle_outlineMódulo 5 | 8 clases
Movimientos
expand_more -
check_circle_outlineMódulo 6 | 5 clases
Configuración dispositivo
expand_more -
check_circle_outlineMódulo 7 | 4 clases
Geolocalización
expand_more -
check_circle_outlineMódulo 8 | 6 clases
Google Maps
expand_more -
check_circle_outlineMódulo 9 | 5 clases
Cámara
expand_more -
check_circle_outlineMódulo 10 | 12 clases
Servicios y LocalStorage
expand_more -
check_circle_outlineMódulo 11 | 7 clases
Promesas y Movimientos
expand_more -
check_circle_outlineMódulo 12 | 13 clases
Notificaciones push
expand_more -
check_circle_outlineMódulo 13 | 5 clases
Publicar app
expand_more
6 comentario(s)
Cuando pulso el botón hace que se recargue toda la página. En el vídeo no se recarga la página cuando Uriel pulsa el botón. Pero a mí sí. Qué estoy haciendo mal?? .
Lo que pasa es lo siguiente: 1. Pulso el botón 2. Hace lo que se ve en el vídeo, se añade otro item a la lista(por unos segundos) 3. Se recarga la página y estoy como al principio. . .
- Cargando repositorios...
-
{{repository.name}}
{{repository.description}}
-
{{repo.name}}
{{repo.description}}
No comprendo el error. Alguien sabe qué ocurre?
compiler.js:485 Uncaught Error: Template parse errors: Can't bind to 'ngModel' since it isn't a known property of 'input'. ("iv class="input-field"> ][(ngModel)]="newRepository.name">
SyntaxError {__zone_symbol__error: Error: Template parse errors:
Unexpected closing tag "div" ("
</form>
</div>
[ERROR ->]</div>
"…, …}
DirectiveNormalizer.normalizeLoadedTemplate @ directive_normalizer.js:127
DirectiveNormalizer.normalizeTemplateSync @ directive_normalizer.js:104
DirectiveNormalizer.normalizeTemplate @ directive_normalizer.js:81
CompileMetadataResolver._loadDirectiveMetadata @ metadata_resolver.js:200
(anonymous) @ metadata_resolver.js:376
CompileMetadataResolver.loadNgModuleDirectiveAndPipeMetadata @ metadata_resolver.js:375
(anonymous) @ compiler.js:171
JitCompiler._loadModules @ compiler.js:170
JitCompiler._compileModuleAndComponents @ compiler.js:125
JitCompiler.compileModuleAsync @ compiler.js:91
PlatformRef_._bootstrapModuleWithZone @ application_ref.js:390
PlatformRef_.bootstrapModule @ application_ref.js:365
377 @ main.ts:10
__webpack_require__ @ bootstrap 1f9aa96c788b541b1fd7:52
702 @ main.bundle.js:157
__webpack_require__ @ bootstrap 1f9aa96c788b541b1fd7:52
webpackJsonpCallback @ bootstrap 1f9aa96c788b541b1fd7:23
(anonymous) @ main.bundle.js:1
Mi codigo en el repositories.component.html es el siguiente:
<div class="row">
<div class="col s6"></div>
<ul class="collection">
<li class="collection-item indigo white-text" [hidden]="repositories.length > 0">
Cargando repositorios...
</li>
<ul class="collection">
<li class="collection-item red accent-2 white-text" [hidden]= "!repository">
<h2>{{repository.name}}</h2>
<p>{{repository.description}}</p>
</li>
<li class= "collection-item" *ngFor="let repo of repositories" (click)="setMainRepository(repo)">
<h3>{{repo.name}}</h3>
<p>{{repo.description}}</p>
</li>
</ul>
<div class="col s6">
<form (submit)="addNewRepo()">
<div class="input-field">
<input type="text" placeholder="Nombre del repositorio">
</div>
<div class="input-field">
<input type="text" placeholder="Descripción del repositorio">
</div>
</form>
</div>
</div>
ERROR TypeError: Cannot read property 'name' of undefined.
<li class="collection-item red accent-2 white-text" [hidden]="!repository"> <h2>{{repository?.name}}</h2> <p>{{repository?.description}}</p> </li>
Me devuelve un error
error_handler.js:47 EXCEPTION: Error in ./RepositoriesComponent class RepositoriesComponent - inline template:10:64 caused by: Error trying to diff '[object Object]'ErrorHandler.handleError @ error_handler.js:47next @ application_ref.js:272schedulerFn @ async.js:82SafeSubscriber.tryOrUnsub @ Subscriber.js:223SafeSubscriber.next @ Subscriber.js:172Subscriber._next @ Subscriber.js:125Subscriber.next @ Subscriber.js:89Subject.next @ Subject.js:55EventEmitter.emit @ async.js:74NgZone.triggerError @ ng_zone.js:278onHandleError @ ng_zone.js:257ZoneDelegate.handleError @ zone.js:236Zone.runTask @ zone.js:157ZoneTask.invoke @ zone.js:335 error_handler.js:49 ORIGINAL EXCEPTION: Error trying to diff '[object Object]'ErrorHandler.handleError @ error_handler.js:49next @ application_ref.js:272schedulerFn @ async.js:82SafeSubscriber.__tryOrUnsub @ Subscriber.js:223SafeSubscriber.next @ Subscriber.js:172Subscriber._next @ Subscriber.js:125Subscriber.next @ Subscriber.js:89Subject.next @ Subject.js:55EventEmitter.emit @ async.js:74NgZone.triggerError @ ng_zone.js:278onHandleError @ ng_zone.js:257ZoneDelegate.handleError @ zone.js:236Zone.runTask @ zone.js:157ZoneTask.invoke @ zone.js:335 error_handler.js:52 ORIGINAL STACKTRACE:ErrorHandler.handleError @ error_handler.js:52next @ application_ref.js:272schedulerFn @ async.js:82SafeSubscriber.__tryOrUnsub @ Subscriber.js:223SafeSubscriber.next @ Subscriber.js:172Subscriber._next @ Subscriber.js:125Subscriber.next @ Subscriber.js:89Subject.next @ Subject.js:55EventEmitter.emit @ async.js:74NgZone.triggerError @ ng_zone.js:278onHandleError @ ng_zone.js:257ZoneDelegate.handleError @ zone.js:236Zone.runTask @ zone.js:157ZoneTask.invoke @ zone.js:335 error_handler.js:53 Error: Error trying to diff '[object Object]' at DefaultIterableDiffer.diff (default_iterable_differ.js:145) at NgFor.ngDoCheck (ng_for.js:135) at Wrapper_NgFor.ngDoCheck (wrapper.ngfactory.js:53) at CompiledTemplate.proxyViewClass.View_RepositoriesComponent0.detectChangesInternal (component.ngfactory.js:239) at CompiledTemplate.proxyViewClass.AppView.detectChanges (view.js:288) at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (view.js:381) at CompiledTemplate.proxyViewClass.View_AppComponent0.detectChangesInternal (component.ngfactory.js:55) at CompiledTemplate.proxyViewClass.AppView.detectChanges (view.js:288) at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (view.js:381) at CompiledTemplate.proxyViewClass.View_AppComponent_Host0.detectChangesInternal (host.ngfactory.js:29)ErrorHandler.handleError @ error_handler.js:53next @ application_ref.js:272schedulerFn @ async.js:82SafeSubscriber.__tryOrUnsub @ Subscriber.js:223SafeSubscriber.next @ Subscriber.js:172Subscriber._next @ Subscriber.js:125Subscriber.next @ Subscriber.js:89Subject.next @ Subject.js:55EventEmitter.emit @ async.js:74NgZone.triggerError @ ng_zone.js:278onHandleError @ ng_zone.js:257ZoneDelegate.handleError @ zone.js:236Zone.runTask @ zone.js:157ZoneTask.invoke @ zone.js:335 error_handler.js:56 ERROR CONTEXT:ErrorHandler.handleError @ error_handler.js:56next @ application_ref.js:272schedulerFn @ async.js:82SafeSubscriber.__tryOrUnsub @ Subscriber.js:223SafeSubscriber.next @ Subscriber.js:172Subscriber._next @ Subscriber.js:125Subscriber.next @ Subscriber.js:89Subject.next @ Subject.js:55EventEmitter.emit @ async.js:74NgZone.triggerError @ ng_zone.js:278onHandleError @ ng_zone.js:257ZoneDelegate.handleError @ zone.js:236Zone.runTask @ zone.js:157ZoneTask.invoke @ zone.js:335 error_handler.js:57 DebugContext {_view: C…e.proxyViewClass, _nodeIndex: 18, _tplRow: 10, _tplCol: 64}ErrorHandler.handleError @ error_handler.js:57next @ application_ref.js:272schedulerFn @ async.js:82SafeSubscriber.__tryOrUnsub @ Subscriber.js:223SafeSubscriber.next @ Subscriber.js:172Subscriber._next @ Subscriber.js:125Subscriber.next @ Subscriber.js:89Subject.next @ Subject.js:55EventEmitter.emit @ async.js:74NgZone.triggerError @ ng_zone.js:278onHandleError @ ng_zone.js:257ZoneDelegate.handleError @ zone.js:236Zone.runTask @ zone.js:157ZoneTask.invoke @ zone.js:335 Subscriber.js:227 Uncaught ViewWrappedError {_nativeError: Error: Error in ./RepositoriesComponent class RepositoriesComponent - inline template:10:64 caused b…, originalError: Error: Error trying to diff '[object Object]' at DefaultIterableDiffer.diff (http://localhost:42…, context: DebugContext}_nativeError: Error: Error in ./RepositoriesComponent class RepositoriesComponent - inline template:10:64 caused by: Error trying to diff '[object Object]' at ViewWrappedError.BaseError as constructor at ViewWrappedError.WrappedError as constructor at new ViewWrappedError (http://localhost:4200/main.bundle.js:36970:16) at CompiledTemplate.proxyViewClass.DebugAppView._rethrowWithContext (http://localhost:4200/main.bundle.js:51730:23) at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (http://localhost:4200/main.bundle.js:51716:18) at CompiledTemplate.proxyViewClass.View_AppComponent0.detectChangesInternal (/AppModule/AppComponent/component.ngfactory.js:55:19) at CompiledTemplate.proxyViewClass.AppView.detectChanges (http://localhost:4200/main.bundle.js:51620:14) at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (http://localhost:4200/main.bundle.js:51713:44) at CompiledTemplate.proxyViewClass.View_AppComponent_Host0.detectChangesInternal (/AppModule/AppComponent/host.ngfactory.js:29:19) at CompiledTemplate.proxyViewClass.AppView.detectChanges (http://localhost:4200/main.bundle.js:51620:14)message: "Error in ./RepositoriesComponent class RepositoriesComponent - inline template:10:64 caused by: Error trying to diff '[object Object]'"stack: "Error: Error in ./RepositoriesComponent class RepositoriesComponent - inline template:10:64 caused by: Error trying to diff '[object Object]'↵ at ViewWrappedError.BaseError as constructor↵ at ViewWrappedError.WrappedError as constructor↵ at new ViewWrappedError (http://localhost:4200/main.bundle.js:36970:16)↵ at CompiledTemplate.proxyViewClass.DebugAppView._rethrowWithContext (http://localhost:4200/main.bundle.js:51730:23)↵ at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (http://localhost:4200/main.bundle.js:51716:18)↵ at CompiledTemplate.proxyViewClass.View_AppComponent0.detectChangesInternal (/AppModule/AppComponent/component.ngfactory.js:55:19)↵ at CompiledTemplate.proxyViewClass.AppView.detectChanges (http://localhost:4200/main.bundle.js:51620:14)↵ at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (http://localhost:4200/main.bundle.js:51713:44)↵ at CompiledTemplate.proxyViewClass.View_AppComponent_Host0.detectChangesInternal (/AppModule/AppComponent/host.ngfactory.js:29:19)↵ at CompiledTemplate.proxyViewClass.AppView.detectChanges (http://localhost:4200/main.bundle.js:51620:14)"__proto: Objectcontext: DebugContextmessage: (...)name: (...)originalError: Error: Error trying to diff '[object Object]' at DefaultIterableDiffer.diff (http://localhost:4200/main.bundle.js:23646:19) at NgFor.ngDoCheck (http://localhost:4200/main.bundle.js:43462:40) at Wrapper_NgFor.ngDoCheck (/CommonModule/NgFor/wrapper.ngfactory.js:53:18) at CompiledTemplate.proxyViewClass.View_RepositoriesComponent0.detectChangesInternal (/AppModule/RepositoriesComponent/component.ngfactory.js:239:20) at CompiledTemplate.proxyViewClass.AppView.detectChanges (http://localhost:4200/main.bundle.js:51620:14) at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (http://localhost:4200/main.bundle.js:51713:44) at CompiledTemplate.proxyViewClass.View_AppComponent0.detectChangesInternal (/AppModule/AppComponent/component.ngfactory.js:55:19) at CompiledTemplate.proxyViewClass.AppView.detectChanges (http://localhost:4200/main.bundle.js:51620:14) at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (http://localhost:4200/main.bundle.js:51713:44) at CompiledTemplate.proxyViewClass.View_AppComponent_Host0.detectChangesInternal (/AppModule/AppComponent/host.ngfactory.js:29:19)stack: (...)proto: WrappedErrorSafeSubscriber.__tryOrUnsub @ Subscriber.js:227SafeSubscriber.next @ Subscriber.js:172Subscriber._next @ Subscriber.js:125Subscriber.next @ Subscriber.js:89Subject.next @ Subject.js:55EventEmitter.emit @ async.js:74NgZone.triggerError @ ng_zone.js:278onHandleError @ ng_zone.js:257ZoneDelegate.handleError @ zone.js:236Zone.runTask @ zone.js:157ZoneTask.invoke @ zone.js:335
¿Alguno me puede ayudar?
Clase 17