4 ms·
Correct AFAIK you can't get end to end type safety in Handlebars, in that if you treat a string as an array it will silently not render something, whereas in Ty
by mc3 7y ago
Correct AFAIK you can't get end to end type safety in Handlebars, in that if you treat a string as an array it will silently not render something, whereas in Typescript / React you would notice.
But... let's forget Handlebars because Typescript/ES6 allows you to write code like this:
mythings.map(thing = `<li>${thing.name}</li>`).join();
And this is React-free and arguably a lot simpler for the needs of a static site, and actually more flexible as your are controlling the character by character output.
And the question is do I want to pull in not just React but Next.js and learn all of it's ways to do this? I think for a static site no.