|
|
|
|
|
by pelme
823 days ago
|
|
This looks great! Building HTML on the server with static types and htmx is a very productive combination! At work, we have been exploring alternatives to templates in our Django project and just released it as a lib to help with this: https://htpy.dev/ |
|
Have you tried to "bring up front" if and for? For example
> if_(cond, tag1(), tag2()) # without eagerly execute both branches
Instead of
> tag1() if cond else tag2()
And
for_(cars, lambda car: car_details(car)) # while still being type checked
Instead of
> [car_details(car) for car in cars]