vaadin no spring boot views not initialising

When using vaadin with spring boot the @Autowired just returns null. The main UI has @SpringUI and my subcomponents view has @Component