Web components are a set of four different technologies that can be used together or separately to build reusable user interface widgets. Just as we can create reusable modules using JavaScript, we can create reusable DOM elements with web component technologies. The four technologies that form the web components are:
- Custom elements
- HTML templates
- Shadow DOM
- HTML imports
The web components were created to provide developers simple APIs to build highly reusable DOM elements. There are many JavaScript libraries and frameworks that focus on providing reusability by organizing the entire web application into simpler components, such as React, Angular, Vue, Polymer, and so on. In the next chapter, we are going to build an entire web application by putting together multiple independent React components. However, despite all the frameworks and libraries...