Another possibility would be the use of WebComponents. With that you can define your own custom html elements, which then get rendered. Check out this quick tutorial about usage of custom elements on MDN

 
Classic DEV Post from Sep 10 '18

What's your atomic bomb?

Inspired by Software that helps, except I disagree with Bertil's implicit asser...

On a path of becoming Full stack Web Developer currently trying to master Javascript! ๐Ÿ˜Ž

DEV is visited by over 2 million software developers per month. You are welcome to publish here or simply read great content.

Get Started