This past week, I ran into a need to dynamically add components using Angular. My specific reason for doing this is that the component I am using is a port of an AngularJS component and so it doesn’t quite conform to the Angular way of doing things. Specifically, I can’t change input values and have the component respond reliably. But, regardless of why I need this functionality, or even why you may need this functionality, I think being able to do this at all is pretty cool.
This week, I thought I’d collect a list of unrelated tricks and tips I’ve learned over the last couple of weeks into one post. Unless you love to read documentation, or you’ve run into problems that these tips solve, I’m guessing you don’t know most of these.
But first, the big new this week…
This past week, while working on a new project, I discovered some secrets to styling Angular2 that I don’t think are very well known.
There are two specific issues I needed to solve this week that took a bit of digging. The first was that I wanted my routes to fade in and out as I move between routes. The second was that I was using a grid control from a third party and I needed to style an inner component. We will cover both as well as some more basic operations.
I’ve been working with Angular2 now since RC0 and I’ve learned quite a few things about Angular2 DOM tips, tricks, and warnings that you’ll want to pay attention to as you get started.