Skip to content

resolvePath output should be prefixed with kit.paths.base #10282

@hmnd

Description

@hmnd

Describe the bug

The current output of resolvePath is not prefixed with the app's base path, making it a hassle to use with a custom base.

Reproduction

  1. Set custom kit.paths.base in svelte.config.js
  2. Call resolvePath()

Logs

No response

System Info

System:
    OS: Linux 6.3 Manjaro Linux
    CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz
    Memory: 5.60 GB / 15.50 GB
    Container: Yes
    Shell: 5.9 - /usr/bin/zsh
  Binaries:
    Node: 18.16.0 - ~/.asdf/installs/nodejs/lts/bin/node
    npm: 9.5.1 - ~/.asdf/plugins/nodejs/shims/npm
    pnpm: 8.6.4 - ~/.local/share/pnpm/pnpm
  Browsers:
    Brave Browser: 114.1.52.129
  npmPackages:
    @sveltejs/adapter-auto: ^2.1.0 => 2.1.0 
    @sveltejs/adapter-cloudflare-workers: ^1.1.2 => 1.1.2 
    @sveltejs/kit: ^1.20.0 => 1.20.4 
    svelte: 4.0.0 => 4.0.0 
    vite: ^4.3.9 => 4.3.9

Severity

annoyance

Additional Information

I'm aware this would introduce a technically breaking change, so perhaps this should be exported as a separate function, or added as a flags to resolvePath to preserve current behavior.

Metadata

Metadata

Assignees

Labels

breaking changefeature / enhancementNew feature or requestneeds-decisionNot sure if we want to do this yet, also design work neededpaths.basebugs relating to `config.kit.paths.base`

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions