Simple demo to provide Server-side-rendering in combination with marko-path-router.
npm install
npm start
-
Lasso is used to render a template file on the server with express.
-
An
include
-tag is used to add a specific component dynamically according to the requested path on the server. (seetemplate.marko
). -
in the
onMount
function (which gets executed on the client) the router is initialized + rendered asynchronously and then replaces the content in the dom accordingly. (seetemplate.marko
).
For more information click here.