StippleUI.jl
StippleUI.jl copied to clipboard
How to easily generate dynamic content
I have a Dict in the model (that can change)
Stipple.@kwdef mutable struct Model <: ReactiveModel
params::R{Dict} = Dict{String, Any}("T_max" => 310.0, "n_segs" => "10", "l_tube" => 10.0, "T_ambient_res" => "Ambient Temperature is 100.0K")
end
in the UI - would like to create many textfield
..and rerender when model changes
[cell(class="q-pa-sm", textfield("", Symbol(""params['$k']"""), label="$k")) for (k,v) in @bind(:params)]
Obviously @bind(:params)] does not work.
I was hoping not to create a giant HTML string in the model - but rather use this like a template.
Any ideas
Chuck