Product
Introducing SSO
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
vue-auto-routing
Advanced tools
Readme
Generate Vue Router routing automatically.
You may want to use vue-cli-plugin-auto-routing which includes all useful features on routing.
$ npm install -D vue-auto-routing
vue-auto-routing resolves Vue Router routing automatically by using vue-route-generator. The routes are generated with the same rules with Nuxt routing.
To use this, you import vue-auto-routing
and pass it into Vue Router constructor options.
// Import generated routes
import routes from 'vue-auto-routing'
import Vue from 'vue'
import Router from 'vue-router'
Vue.use(Router)
export default new Router({
// Pass the generated routes into the routes option
routes
})
You also need to add a webpack plugin vue-auto-routing provides. The plugin options are the same as vue-route-generator options
// webpack.config.js
const VueAutoRoutingPlugin = require('vue-auto-routing/lib/webpack-plugin')
module.exports = {
// ... other options ...
plugins: [
new VueAutoRoutingPlugin({
// Path to the directory that contains your page components.
pages: 'src/pages',
// A string that will be added to importing component path (default @/pages/).
importPrefix: '@/pages/'
})
]
}
MIT
FAQs
Generate Vue Router routing automatically
The npm package vue-auto-routing receives a total of 697 weekly downloads. As such, vue-auto-routing popularity was classified as not popular.
We found that vue-auto-routing demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.