Skip to content

Commit

Permalink
readme
Browse files Browse the repository at this point in the history
  • Loading branch information
40818419 committed Sep 9, 2018
1 parent 3bfc434 commit 0e5e7e7
Show file tree
Hide file tree
Showing 9 changed files with 3,381 additions and 5,147 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,12 @@ Generate sitemap.xml by vue-router configuration

## Example usage

```
```js
import VueRouterSitemap from 'vue-router-sitemap';
import path from 'path';
import { router } from 'router';

...
export const sitemapMiddleware = () => {
return (req, res) => {
res.set('Content-Type', 'application/xml');
Expand All @@ -30,4 +31,7 @@ export const sitemapMiddleware = () => {
return res.sendFile(staticSitemap);
};
};

app.get('/sitemap.xml', sitemapMiddleware());
...
```
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export { default } from './lib';
export { default } from './src';
Loading

0 comments on commit 0e5e7e7

Please sign in to comment.