skip to Main Content

I’d like to be able to render javascript templates using the Mithril JS framework on the server for SEO and first load purposes and have them run in the browser.

2

Answers


  1. Chosen as BEST ANSWER

    See this blog post: https://gist.github.com/StephanHoyer/bddccd9e159828867d2a

    And this example repo: https://github.com/StephanHoyer/mithril-isomorphic-example

    to run the demo, simply

    Clone the repo
    cd into it
    run npm install
    run node server
    

  2. Give my new framework (https://github.com/ezramorse/mens) a whirl for an out of box solution

    npm install mens
    node node_modules/mens/example/server.js
    

    Or just require(‘mens’) from the root and start from scratch!

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search