mod add_remove; mod assembly; mod display; mod engine; mod outline; use rustc_hash::FxHashSet; use sycamore::prelude::*; use add_remove::AddRemove; use assembly::{Assembly, ElementKey}; use display::Display; use outline::Outline; #[derive(Clone)] struct AppState { assembly: Assembly, assembly_serial: Signal, selection: Signal> } impl AppState { fn new() -> AppState { AppState { assembly: Assembly::new(), assembly_serial: create_signal(0), selection: create_signal(FxHashSet::default()) } } } fn main() { sycamore::render(|| { provide_context(AppState::new()); view! { div(id="sidebar") { AddRemove {} Outline {} } Display {} } }); }