KO
|
EN
gitlite — search
Search
#python
#java
#python3
#arduino
#golang
#machine-learning
#rust
#html
#flask
#javascript
#seismology
#nodejs
datastar-zig-archived
★ 16
Open GitHub ↗
Official Datastar Zig SDK.
Download README (.md)
Explore Similar Repositories
mitou-report
:
未踏IT人材発掘・育成事業用 成果報告書Template (Typst)
multi-variate-parallel-transformer
:
Repository for paper "A foundation model with multi-variate parallel attention to generate neuronal activity"
morpho-lite-apps
:
A monorepo containing the Lite and Fallback apps
holographic
:
holographic card ⋆˙⟡
clam
:
No description available.
// repository documentation
Was this content helpful?
★ 0
(0 ratings)
Select Rating:
★
★
★
★
★
Submit Feedback
Recent Feedback
×
Download README
Do you want to download the
README.md
file for
datastar-zig-archived
?
Download (.md)
# Datastar Zig SDK The Datastar SDK in Zig, with support for http.zig and tokamak. ## Installation Install with `zig fetch --save git+https://github.com/starfederation/datastar-zig` and add datastar as a dependency. ```zig const datastar = b.dependency("datastar", .{ .target = target, .optimize = optimize, .framework = .httpz, // or .tokamak }).module("datastar"); exe.root_module.addImport("datastar", datastar); ``` ## Usage ```zig const datastar = @import("datastar").httpz; // Creates a new `ServerSentEventGenerator`. var sse = try datastar.ServerSentEventGenerator.init(res); // Merges HTML fragments into the DOM. try sse.mergeFragments("<div id='question'>What do you put in a toaster?</div>", .{}); // Merges signals into the signals. try sse.mergeSignals(.{ .response = "", .answer = "bread" }, .{}); ``` Full examples at https://github.com/starfederation/datastar/tree/main/examples/zig