Replace @Controller with @RestController
ProprietaryWhen a class is annotated with @Controller and either the class itself or all of its handler methods are annotated with @ResponseBody, the class can use @RestController instead. This removes the need for individual @ResponseBody annotations.
io. moderne. java. spring. framework. ReplaceControllerWithRestControllermod run . --recipe= io. moderne. java. spring. framework. ReplaceControllerWithRestControllerInstall it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.