Code cleanup and refactoring to enhance consistency (#1695)

- Move message handler payload data into structs
- Organize the file structure used by `editor/src/messages/portfolio/document` `/node_graph` and `/graph_operation`
- Make derive attributes use `serde::Serialize, serde::Deserialize` consistently instead of `use serde::{Deserialize, Serialize};` imports
- Various other code cleanup and refactoring
This commit is contained in:
Keavon Chambers
2024-03-20 21:28:51 -07:00
committed by GitHub
parent ed3f7acdd7
commit 0a9bd41be1
134 changed files with 1860 additions and 1865 deletions

View File

@@ -30,7 +30,7 @@ Comments should be placed on a separate line, but exceptions are permitted where
At the top of Rust files, please follow the convention of separating imports into three blocks, in this order:
1. Local (`use super::` and `use crate::`)
2. First-party crates (e.g. `use editor::`)
3. Third-party libraries (e.g. `use std::` or `use serde::`)
3. Third-party libraries (e.g. `use std::` or `use glam::`)
Combine related imports with common paths at the same depth. For example, the lines `use crate::A::B::C;`, `use crate::A::B::C::Foo;`, and `use crate::A::B::C::Bar;` should be combined into `use crate::A::B::C::{self, Foo, Bar};`. But do not combine imports at mixed path depths. For example, `use crate::A::{B::C::Foo, X::Hello};` should be split into two separate import lines. In simpler terms, avoid putting a `::` inside `{}`.