2 ms·
I use something like this for my personal website. I don't know how fast text-based template systems are, but I can do a clean build of my entire website in un
by klodolph 5y ago
I use something like this for my personal website.
I don't know how fast text-based template systems are, but I can do a clean build of my entire website in under half a second. That seems pretty fast to me. I've been adding content to it for over 20 years now... it's not a massive site since it's just me, but it's not exactly small either.
Every page is authored as HTML, with some extra headers at the top. It's parsed as HTML5. The processor will apply templates in a fairly simple way... merge everything in <head>, merge everything in <body>. There's a special tag for templates that means "put the <body> here, instead of merging".
Any given piece of HTML will be parsed / unparsed only twice, because the templates work on DOM manipulation. The second parse / unparse is there because I use an HTML minifier, and the HTML minifier has a bytes in/bytes out interface.
> Another is that you run into "hygenic macro" problems if you want to merge random DOM trees into each other:...
This is a beast of a problem. If I need an ID in a template that may get used in multiple places, then there's some piece of code somewhere generating the ID.
My experience is that it really becomes a problem when you have large, large sites with tons of people working on them, and it's not a problem at all for one person.
> Finally it would be really nice to have a reliable WYSIWYG HTML editor, particularly one that would help you use CSS classes in a disciplined way to customize the system to add whatever markup features you want for your site.
It's called "Dreamweaver". Truly one of the most powerful web authoring tools ever made.
- PaulHoule 5y agoI want to like Dreamweaver but on a desktop replacement laptop it takes several seconds for characters to appear when I type. Selection, where the cursor ends up when I click on something and where the cursor goes when I hit the arrow keys are all erratic enough to make me wonder if my computer is possessed by the devil. I've submitted so many tickets to Adobe about strange problems with Dreamweaver that it's a wonder I haven't been hellbanned from their issue tracker.
- klodolph 5y agoAll my experience with Dreamweaver is many years out of date. I don't doubt that it's become slow.