Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for seed 0.8.0? #2

Open
olof-nord opened this issue May 14, 2021 · 0 comments
Open

Support for seed 0.8.0? #2

olof-nord opened this issue May 14, 2021 · 0 comments

Comments

@olof-nord
Copy link

It seems that seed_hooks v0.1.4 does not support seed v0.8.0.

A reproducible test is to edit the seed-hooks-quickstart demo, and use version 0.8.0 of seed.

This is the error message:

error[E0308]: mismatched types
  --> src/lib.rs:50:9
   |
50 |         button!["The count is ", count, count.on_click(|c| *c +=1 )],
   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected struct `seed::virtual_dom::node::el::El`, found struct `seed::virtual_dom::El`
   |
   = note: expected mutable reference `&mut seed::virtual_dom::node::el::El<_>`
              found mutable reference `&mut seed::virtual_dom::El<_>`
   = note: perhaps two different versions of crate `seed` are being used?
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0599]: the method `update_el` exists for struct `seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>`, but its trait bounds were not satisfied
  --> src/lib.rs:50:9
   |
50 |         button!["The count is ", count, count.on_click(|c| *c +=1 )],
   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ method cannot be called on `seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>` due to unsatisfied trait bounds
   | 
  ::: /home/olof/.cargo/registry/src/gh.neting.cc-1ecc6299db9ec823/seed-0.7.0/src/virtual_dom/event_handler_manager/event_handler.rs:6:1
   |
6  | pub struct EventHandler<Ms> {
   | ---------------------------
   | |
   | doesn't satisfy `<_ as std::iter::Iterator>::Item = _`
   | doesn't satisfy `_: seed::virtual_dom::UpdateEl<_>`
   | doesn't satisfy `_: seed::virtual_dom::UpdateElForIterator<_>`
   | doesn't satisfy `_: std::iter::Iterator`
   |
   = note: the following trait bounds were not satisfied:
           `<seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_> as std::iter::Iterator>::Item = _`
           which is required by `seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: seed::virtual_dom::UpdateElForIterator<_>`
           `seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: std::iter::Iterator`
           which is required by `seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: seed::virtual_dom::UpdateElForIterator<_>`
           `seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: seed::virtual_dom::UpdateEl<_>`
           which is required by `&seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: seed::virtual_dom::UpdateEl<_>`
           `<&seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_> as std::iter::Iterator>::Item = _`
           which is required by `&seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: seed::virtual_dom::UpdateElForIterator<_>`
           `&seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: std::iter::Iterator`
           which is required by `&seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: seed::virtual_dom::UpdateElForIterator<_>`
           `<&mut seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_> as std::iter::Iterator>::Item = _`
           which is required by `&mut seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: seed::virtual_dom::UpdateElForIterator<_>`
           `&mut seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: std::iter::Iterator`
           which is required by `&mut seed::virtual_dom::event_handler_manager::event_handler::EventHandler<_>: seed::virtual_dom::UpdateElForIterator<_>`
   = help: items from traits can only be used if the trait is in scope
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
help: the following trait is implemented but not in scope; perhaps add a `use` for it:
   |
7  | use seed::virtual_dom::update_el::UpdateEl;
   |

error: aborting due to 2 previous errors

Really cool library, thanks for putting this together!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant