Skip to content

Instantly share code, notes, and snippets.

@felipebastosweb
Created November 28, 2023 14:33
Show Gist options
  • Save felipebastosweb/fffafe1e7b76d4d3d054fffcbf8f3605 to your computer and use it in GitHub Desktop.
Save felipebastosweb/fffafe1e7b76d4d3d054fffcbf8f3605 to your computer and use it in GitHub Desktop.
Integração com o MithrilJS
// acrescente <script src="https://unpkg.com/mithril/mithril.js"></script> no index.html
export class Game
{
constructor(self)
{
// lista de levels do usuário (página)
this.levelList = {};
}
run(self)
{
return m.route(document.body, "/", this.levelList)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment