Is there a way to use spring hateoas with router function? It seems to me that the only way would be to replace my RouterFunction by RestController.
@Configuration @EnableWebFlux class RouterConfig : WebFluxConfigurer { @Bean fun mainRouter(testHandler: TestHandler) = coRouter { "/employee".nest { accept(APPLICATION_JSON).nest { "/{ID}".nest { GET("",testHandler::getEmployeeByID) } } } }
Can I add hateaos link directly in the above function instead of creating a restController class?`