Skip to content

syarul/todomvc-lua-luasocket-htmx-_hyperscript

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

 ooooo   ooooo ooooooooooooo ooo        ooooo ooooooo  ooooo
 `888'   `888' 8'   888   `8 `88.       .888'  `8888    d8'
  888     888       888       888b     d'888     Y888..8P
  888ooooo888       888       8 Y88. .P  888      `8888'
  888     888       888       8  `888'   888     .8PY888.
  888     888       888       8    Y     888    d8'  `888b
 o888o   o888o     o888o     o8o        o888o o888o  o88888o
===========================================================
        Build with LUA, LUASOCKET, HTMX & _HYPERSCRIPT

Lua and Cypress Tests

HTMX TodoMVC Link
Go, Templ 🌄
Rust, Astra, Maud 🌠
ExpressJS, Typescript, React ✈️
AdonisJS, Typescript, React 🎡
Lua, Luasocket

E2E Testing

app.cy.js.mp4

Emulating the functionalities of modern frameworks which is base on React TodoMVC. This demonstration serves to showcase that HTMX, when paired with _hyperscript, can replicate if not all the behaviors typically associated with most modern client framework with minimum needs to write javascript.

Usage & Setup

Get latest Lua and all dependencies

sudo apt-get update
curl -LRO https://www.lua.org/ftp/lua-5.4.7.tar.gz
tar -xzvf lua-5.4.7.tar.gz
cd lua-5.4.7/
make linux
sudo make install
wget https://luarocks.org/releases/luarocks-3.11.1.tar.gz
tar zxpf luarocks-3.11.1.tar.gz
cd luarocks-3.11.1/
./configure && make && sudo make install
sudo luarocks install luasocket
sudo luarocks install luafilesystem
sudo luarocks install lua-cjson
sudo luarocks install luax

See https://github.com/syarul/luax more to understand how transpiling HTML is done in Lua.

  • run with lua server.lua
  • visit http://localhost:8888
  • for e2e testing, run in the root folder git clone https://github.com/cypress-io/cypress-example-todomvc
  • cd cypress-example-todomvc
  • npm install
  • if you need to see the test in browser run npm run cypress:open
  • for headless test npm run cypress:run

HTMX

Visit https://github.com/rajasegar/awesome-htmx to look for HTMX curated infos

Todo

  • Perf test (consolidate with other langs rust, zig, odin, ocaml, etc+)

About

TodoMVC build with LUAX, LUA, LUASOCKET, HTMX & _HYPERSCRIPT

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages