GithubHelp home page GithubHelp logo

sitemap-ts's Introduction

Hi there, I'm JB Aubrée 👋

I'm a Front-end Developer, VueJS, UnoCSS, Vite lover.


jbaubree's GitHub stats


Top Langs

sitemap-ts's People

Contributors

jbaubree avatar kantikuijk avatar mikezotovdev avatar renovate[bot] avatar uewtwo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

sitemap-ts's Issues

Dynamic routes like /user/[id] generated in sitemap

when ssg build with options {"includeAllRoutes": true} or with a includedRoutes function, file like /user/[id].vue got generated to /user/:id.html , the exclude option support string only, so how could i remove these from the result?

Does not append dynamic routes

Hello,

Version 0.4.0 broke this package. Version 0.3.0 works properly.

Recently, the sitemap output does not correctly append the dynamic route. Instead, it just puts 'route' at the end of each item.

For instance, this is what happens when I give dynamicRoutes: ['/about'] as an option:

    <url>
        <loc>
            https://example.com/route
        </loc>
        <lastmod>
            2023-05-06T04:35:50.973Z
        </lastmod>
        <changefreq>
            daily
        </changefreq>
        <priority>
            1.0
        </priority>
    </url>

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • chore(deps): update dependency taze to v0.13.9
  • fix(deps): update dependency @antfu/utils to v0.7.10
  • 🔐 Create all rate-limited PRs at once 🔐

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

github-actions
.github/workflows/ci.yml
  • actions/checkout v4
  • pnpm/action-setup v4
  • actions/setup-node v4
  • actions/checkout v4
  • pnpm/action-setup v4
  • actions/setup-node v4
npm
package.json
  • @antfu/utils ^0.7.8
  • fast-glob ^3.3.2
  • sitemap ^8.0.0
  • xml-formatter ^3.6.2
  • @antfu/eslint-config ^2.18.1
  • @antfu/ni ^0.21.12
  • @babel/types ^7.24.5
  • @types/node ^20.12.12
  • @vitest/coverage-v8 ^1.6.0
  • bumpp ^9.4.1
  • eslint ^9.3.0
  • eslint-plugin-format ^0.1.1
  • esno ^4.7.0
  • lint-staged ^15.2.4
  • pnpm ^9.1.2
  • rimraf ^5.0.7
  • simple-git-hooks ^2.11.1
  • taze ^0.13.8
  • typescript ^5.4.5
  • unbuild ^2.0.0
  • vite ^5.2.11
  • vitest ^1.6.0
  • pnpm 9.1.2

  • Check this box to trigger a request for Renovate to run again on this repository

TypeError: fg.sync is not a function

seeing some site build failure using latest sitemap-ts 1.7.2

1:02:48 PM: build error:
1:02:48 PM: fg.sync is not a function
1:02:48 PM: TypeError: fg.sync is not a function
1:02:48 PM:     at getRoutes (file:///opt/build/repo/node_modules/.pnpm/[email protected]/node_modules/sitemap-ts/dist/index.mjs:83:11)
1:02:48 PM:     at generateSitemap (file:///opt/build/repo/node_modules/.pnpm/[email protected]/node_modules/sitemap-ts/dist/index.mjs:132:18)
1:02:48 PM:     at Object.buildEnd (file:///opt/build/repo/runatlantis.io/.vitepress/config.ts.timestamp-1716397363039-ee4c35203ed95.mjs:219:5)
1:02:48 PM:     at build (file:///opt/build/repo/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected]/node_modules/vitepress/dist/node/serve-BwR5EPUJ.js:46795:30)

image

relates to runatlantis/atlantis#4588

Error during lint-staged in vitest.config.ts file

Hi! I'm about to create a MR to your repo with a new feature, but I encountered an error during lint-staged check run. The error is reproducible on the current master version of your repo, so probably it's not subject to my MR.

It seems to me, the config is written incorrectly, and there are some articles how to configure vitest.config.ts - all of them suggest another structure - code below (some articles - one, two, three). However, if I try to use the following code, nothing happens (just an empty output...or maybe it's the expected behavior?)

vitest.config.ts file

import { defineConfig } from 'vitest/config'

export default defineConfig({
  test: {
    name: 'config',
    setupFiles: 'test/setup.ts',
  },
})

Here is what happen with the old config file. Simply speaking, the type is wrong.
Just open file (I use WebStorm) and see that:

image

Console after manual run of tsc --skipLibCheck --noEmit

image

If I run my code with a possible fix:

image

FYI: I use yarn, TS 4.9.4.

Could you help me to figure out that issue? Thanks!

Ability to add base path

Hi! I'm using your library to generate a sitemap for a VitePress site (https://abbekeultjes.nl/honeycomb). I'd like to be able to generate links in the sitemap for a hostname and base path (not sure if that's the best name): https://abbekeultjes.nl/honeycomb/. When I pass that url for the hostname option, the /honeycomb/ part is removed. This makes sense, since it's not part of the hostname.

Could you add an option to specify any path elements that get appended to the hostname?

Thanks!

If you pass to `outDir` absolute path in will convert it to relative and crash.

If you pass to outDir absolute path in will convert it to relative and crash.

    generateSitemap({
      outDir: 'C:/Users/kozac/Dev/kozack.me/docs/.vitepress/dist',
      dynamicRoutes: pages,
    })
Error: ENOENT: no such file or directory, open 'C:\Users\kozac\Dev\kozack.me\C:\Users\kozac\Dev\kozack.me\docs\.vitepress\dist\robots.txt'
    at Object.openSync (node:fs:599:3)
    at Object.writeFileSync (node:fs:2221:35)
    at generateSitemap (C:\Users\kozac\Dev\kozack.me\node_modules\sitemap-ts\dist\index.cjs:122:6)
    at Object.buildEnd (C:\Users\kozac\Dev\kozack.me\docs\.vitepress\config.js:72:43)
    at build (file:///C:/Users/kozac/Dev/kozack.me/node_modules/vitepress/dist/node/serve-1b26f7f9.js:41479:59)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.