antfu-collective/vite-ssg

`base` is not working correctly when using a relative value.

salomaosnff opened this issue · 1 comments

Describe the bug

When using ./ as the base value in the vite.config.ts file, all image URLs become invalid.

Reproduction

https://github.com/salomaosnff/bug-vite-ssg

System Info

System:
    OS: Linux 6.1 Manjaro Linux
    CPU: (16) x64 AMD Ryzen 7 5700G with Radeon Graphics
    Memory: 7.40 GB / 14.92 GB
    Container: Yes
    Shell: 5.9 - /usr/bin/zsh
  Binaries:
    Node: 16.20.0 - ~/.nvm/versions/node/v16.20.0/bin/node
    Yarn: 1.22.19 - ~/.yarn/bin/yarn
    npm: 8.19.4 - ~/.nvm/versions/node/v16.20.0/bin/npm
  Browsers:
    Brave Browser: 113.1.51.118
    Firefox: 113.0

Used Package Manager

yarn

Validations

  • Follow our Code of Conduct
  • Read the Contributing Guide.
  • Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
  • Check that this is a concrete bug. For Q&A, please open a GitHub Discussion instead.
  • The provided reproduction is a minimal reproducible of the bug.
Eacolt commented

I am the same problem, how to solve it?