Conversation
|
FWIW, you should be able to compile and serve almost all the examples unchanged so long as |
34c32f5 to
d4ad7aa
Compare
luleyleo
left a comment
There was a problem hiding this comment.
Looks good, the readme instructions work.
Seems to have unused dependencies tho.
|
This builds and runs for me perfectly :) I would add two things.
|
xStrom
left a comment
There was a problem hiding this comment.
As this is a new package it needs to also be added to the CI.
It's pretty straightforward, look into the ci.yml file and copy the druid-wasm-examples clippy/build steps.
|
@Finnerale @xStrom sorry for the long delay but I've finally addressed your comments. Not sure why the Cargo.lock is conflicting, it wasn't yesterday. |
|
It's conflicting because it doesn't exist anymore. You need to rebase with |
luleyleo
left a comment
There was a problem hiding this comment.
Thanks for continuing this!
Some more nitpicking, but then it should be good to go.
|
|
||
| const VERTICAL_WIDGET_SPACING: f64 = 20.0; | ||
| const TEXT_BOX_WIDTH: f64 = 200.0; | ||
| const WINDOW_TITLE: LocalizedString<HelloState> = LocalizedString::new("Hello World!"); |
There was a problem hiding this comment.
Window titles can be normal strings now 🎉
There was a problem hiding this comment.
looks like window title isn't used by the web version so I'm leaving it off entirely now
| // hello.rs example. | ||
| #[wasm_bindgen] | ||
| pub fn wasm_main() { | ||
| std::panic::set_hook(Box::new(console_error_panic_hook::hook)); |
There was a problem hiding this comment.
Would be nice if this one could get a comment, explaining that this is necessary to get panic messages on wasm32.
There was a problem hiding this comment.
I was unaware of what this actually did, so I hope my copy of your explanation is sufficient.
|
Okay, I believe I've addressed all comments. Also, I realized I hadn't updated the index.js to refer to the different package name, so that's fixed now as well. |
This depends on #759 and should be merged after (and will def need some changes before that!).
Just wanted to get something up so I could get some feedback. A couple questions: