4 ms·
Thanks for creating Rivet! I use it for several separate pieces of interactive functionality on my home server, the way some may use PHP. The API is simple enou
by networked 3y ago
Thanks for creating Rivet! I use it for several separate pieces of interactive functionality on my home server, the way some may use PHP. The API is simple enough, and if you already know Tcl it doesn't take you long to get started. I like how easy it is to add file uploading to an existing form with ::rivet::upload.
> Tcl was... is a fantastic language for doing web development.
Except for JSON. You can't round-trip JSON through Tcl because dicts are lists are strings. There are solutions out there (https://wiki.tcl-lang.org/page/JSON https://wiki.tcl-lang.org/page/JSON), I even wrote a few of them, but in the end there is a fundamental impedance mismatch. It gets in the way of emitting JSON from quick hacks or the REPL because you essentially need an explicit schema.
For text-based templates, Tcl is good. I have written code to generate CSS in Tcl and loved how well the language fit the task.
(I found this out for CSS when I contributed a responsive stylesheet for https://www.tcl-lang.org/ https://www.tcl-lang.org/. I wanted a CSS preprocessor to avoid repetition, and one that would never break, at least not before Tcl did. I think it worked well. The template uses subst and some variables. It is Tcl 9-ready. :-) I recommend trying it if you do web development in Tcl.)