Skip to content
Advertisement

Tag: angular

Angular why asterisk (*)

In Angular document, * and template, we know that the *ngIf, *ngSwitch, *ngFor can be expanded to ng-template tag. My question is: I think the ngIf or ngFor without * can also be translated and expanded to template tag by Angular engine. The following code would be the same as So why bother designing a strange symbol asterisk(*) in Angular?

Angular 2 not updating until any object is clicked

The following is something I’m trying to get working based on the Angular Tutorial. And the View sobots.data looks to be returning the data object as expected – however it’s still not updating until I click on any button/route/any event is fired. No errors show up in the console and I’m quite confused! I’ve gone ahead and tried to ensure

Angular2 : render a component without its wrapping tag

I am struggling to find a way to do this. In a parent component, the template describes a table and its thead element, but delegates rendering the tbody to another component, like this: Each myResult component renders its own tr tag, basically like so: The reason I’m not putting this directly in the parent component (avoiding the need for a

How can I share an Angular 2 component between multiple Angular 2 projects?

Ideally, I’d like to create a stand-alone Angular 2 component (with tests) and then re-use it between two or three different Angular 2 sites. What are the good ways to achieve this? And a bonus question – do any 3rd party Angular 2 components exist? Answer UPDATE OFFICIAL Angular CLI https://angular.io/guide/creating-libraries You can create an angular2 component library (with tests)

Advertisement