We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 19902b7 commit f745568Copy full SHA for f745568
make_sitemap.js
@@ -9,7 +9,8 @@ const { createSitemap } = require('sitemap')
9
const ensureTrailingSlash = (url) => (url.endsWith('/') ? url : `${url}/`)
10
11
const getPaths = async ({ distPath, exclude = [], cwd = '.' }) => {
12
- const htmlFiles = `${getRelPath(distPath, cwd)}/**/**.html`
+ const relPath = getRelPath(distPath, cwd)
13
+ const htmlFiles = relPath === '' ? '**/**.html' : `${relPath}/**/**.html`
14
const excludeFiles = exclude.map((excludedPath) => `!${getRelPath(excludedPath, cwd).replace(/^!/, '')}`)
15
16
const lookup = [htmlFiles, ...excludeFiles]
0 commit comments