1

I'm trying to migrate a Vaadin 8 application to Vaadin 11.

I'm trying to use VaadinServlet and UI:

@WebServlet(value = "/*", asyncSupported = true)
@VaadinServletConfiguration(productionMode = false, ui = TestUi.class)
public class TestServlet extends VaadinServlet {
}

public class TestUi extends UI {
  @Override
  protected void init(VaadinRequest request) {
    add(new Label("Test"));
  }
}

I get:

enter image description here

Can / do I have to disable Router?

I double checked, there is no class annotated with @Route.

Update: The migration guide states: enter image description here

So I am still confused about why and where I am supposed to put the Route annotation in this scenario.

4

1 回答 1

3

您需要@Route在 Vaadin 10 中至少拥有一个。由于您正在迁移,您可能需要在此处查看文档:https ://vaadin.com/docs/v10/flow/migration/1-migrating-v8-v10 .html

于 2018-11-21T07:54:21.430 回答