Skip to content

YosifG/Vue-Router-Tiny-Sitemap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Vue-Router-Tiny-Sitemap

A hassle-free way to generate a sitemap.xml for your Vue Single Page Application.

Installation


npm i vue-router-tiny-sitemap

Prerequisites:

In order to use this package, you will need to have 'xmlbuilder2' as well as 'file-saver' installed.

Example usage

Vue router tiny sitemap takes your routes and the base url of your website, constructs a sitemap.xml file and automatically starts a download for it. This process takes place in your browser. For esample, you would have to start your server with "npm run serve", then visit the localhost URL. This will then automatically commence the sitemap.xml download, and output a success message in the console.

// src/router.js
const routes = [
    //your Vue-router routes array
]

var generateSitemap = require("vue-router-tiny-sitemap")
generateSitemap(routes, "baseURL.com")

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published