Outline: switch from "Editor" to "App"
This commit is contained in:
parent
634e97b659
commit
20b96a9764
2 changed files with 6 additions and 6 deletions
|
@ -9,13 +9,13 @@ struct Element {
|
|||
rep: DVector<f64>,
|
||||
}
|
||||
|
||||
struct EditorState {
|
||||
struct AppState {
|
||||
elements: Signal<Vec<Element>>
|
||||
}
|
||||
|
||||
#[component]
|
||||
pub fn Editor() -> View {
|
||||
let state = EditorState {
|
||||
pub fn App() -> View {
|
||||
let state = AppState {
|
||||
elements: create_signal(vec![
|
||||
Element {
|
||||
id: String::from("central"),
|
|
@ -1,13 +1,13 @@
|
|||
use sycamore::prelude::*;
|
||||
|
||||
mod editor;
|
||||
mod app;
|
||||
|
||||
use editor::Editor;
|
||||
use app::App;
|
||||
|
||||
fn main() {
|
||||
sycamore::render(|| {
|
||||
view! {
|
||||
Editor {}
|
||||
App {}
|
||||
}
|
||||
});
|
||||
}
|
Loading…
Add table
Reference in a new issue