基于SpringBoot扩展SpringMVC

//导入配置
@Configuration
//继承WebMvcConfigurer
public class mvcConfig implements WebMvcConfigurer {
    //视图转换
    @Override
    public void addViewControllers(ViewControllerRegistry registry) {
        registry.addViewController("/").setViewName("login");
    }
}

 

posted @ 2020-07-13 22:46  shouyaya  阅读(202)  评论(0编辑  收藏  举报