critique of vibe.d

Adam D. Ruppe via Digitalmars-d digitalmars-d at puremagic.com
Thu Jul 10 11:28:31 PDT 2014


On Thursday, 10 July 2014 at 18:05:35 UTC, Nick Sabalausky wrote:
> Common headers, common footers, common CSS imports, etc.

The way I do it is every html file is a full tree, so there isn't 
really a common header/footer and instead a common skeleton. So 
we'd have

skeleton.html
<html><head> all that stuff </head>
<body>
   header
   <div id="content-container"></div>
   footer
</body></html>

All as a single file. Then each page would be a file that 
contains a div and the content.

To view a whole page, you simply paste that code into the 
#content-container on the main page, which can be done with a 
javascript request easily enough, or just plain text editor 
copy/paste, and move it back into the independent file when 
finished with it.



More information about the Digitalmars-d mailing list