This repo is really all about component patterns and mostly component patterns in angular. I've used it as the example code for two different talks, which are really the same talk with different titles.
React and Angular are the most widely used front-end libraries today. Both tools have undoubtedly enabled developers to become more productive, and both have seen a lot of maturation in the past couple years. Rather than pitting the two against each other in a high-stakes death match, perhaps there exist opportunities for developers of one library to learn from the best practices of the other. In this talk, though perhaps not as exciting as a bloody cage fight, we’ll learn about the most popular patterns circulating in the React community and see how we can apply the same techniques to write better Angular code.
Getting started with Angular components is easy enough, but sometimes we need more than simple inputs and outputs to satisfy complex scenarios. Perhaps your component requires complicated local state management? Maybe two of your components need to play nicely together, yet maintain an appropriate level of separation? How can we efficiently reuse code between multiple components that require the same behavior but display different templates? In this talk, we’ll leverage Angular features like form controls, templates, and queries to build components with flexible, intuitive APIs and explore a couple of code smells that signal a need for better patterns.