How to link MainView with SecondView

hi,

i am trying to connect MainView with HelloWorldView but i am getting errors.

I pasted MainView and HelloWorldView

What i am doing wrong?
image.png
image.png

The annotations should be put on the class definition, not on the constructor

For more information on routing take a look here Defining Routes | Routing & Navigation | Vaadin Docs and here Navigating Between Routes | Routing & Navigation | Vaadin Docs

ooo

thanks!