Summary: The author discusses the various ways to template data into HTML without additional dependencies, focusing on using JavaScript template literals and functions instead of traditional templating languages. Components are defined as functions that return strings, with the option to include children. The approach is flexible, composable, and does not require external frameworks. The author demonstrates how to create components and layouts using this method, emphasizing the simplicity and versatility of the technique. Additionally, the author highlights the possibility of achieving JSX-like syntax with small dependencies. The post encourages using this method for templating to avoid the complexities associated with other templating languages.
https://blog.jim-nielsen.com/2021/javascript-templating/