Yes, obviously, but there are de-referincing/borrwowing/trait problem.
If you want to check the Trait: https://docs.rs/ratatui/latest/ratatui/widgets/trait.Widget.html
If you want to check what function do I need to run: https://docs.rs/ratatui/latest/ratatui/terminal/struct.Frame.html#method.render_widget
So the struct is something like
struct Panel<T: Widget> { data: T }
(tried also with Box, Rc, &mut T and Box<dyn Widget>
I need to implement a method for Panel which simply uses the function linked above. (so just asks for a Frame, the Rect type is generated by my other function)
I checked the code and noticed that I wrote
&self
as the parameter 🤦🏻Now everything works. Thanks man