Matchmaking with HTMLElement & fetch

After having fun with HTMLElement at the boom, I wanted to create a simple HTMLElement that depends on async server data. And since JS has the fetch method, it’s simple as can be.

The component is simple: a box that if you refresh a key or reset the person gender, will reload some random dude fro a server API according to the new data. The APP will have some external events that will set the element data and trigger the API load.

Although the APP looks simple and trivial, it’s a POC to display how you can create an independent element that loads the data from both the APP data, APP events or live independently. This was supposed to represent an option to replace out graph visualization inside as existing heavy APP.

Since there is nothing interesting I haven’t written about at “the boom”, I’ll write nothing…