Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

请问当页面输入URL地址时候如何把controller中的路由文件夹名字省略掉 #61

Open
alvinmachao opened this issue May 28, 2018 · 2 comments

Comments

@alvinmachao
Copy link

如何配置能省略掉路由的文件夹名字呢?比如说在controller中有一个文件夹routers里面都是项目路由,在页面输入URL时候就是localhost:3000/routers/eg... 请问怎么配置这个routers可以省略掉

@xiongwilee
Copy link
Owner

配置router.prefix即可,参考,config/main.xx.js

// router配置
  router: {
    prefix: {
      test: '/test'
    }
  },

@alvinmachao
Copy link
Author

感谢您的回答,我其实有试过配置这个参数,不过没成功,我再试试吧!还有一个问题想请教您就是我现在想做一个VUE项目,也基于此框架,不知道您那里有没有合适的demo?本人有点小白,若是问题比较小白还请谅解 谢谢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants