kit icon indicating copy to clipboard operation
kit copied to clipboard

Document `workbench.editor.labelFormat` setting

Open ethanfox opened this issue 2 years ago • 3 comments

Describe the problem

Whenever I'm working on my svelteKit project all of that tabs have "+page.svelte" at the top with their parent folder in smaller letters. e.g.

+page.svelte

/login

Describe the proposed solution

It would be great if there were a way for the parent folder to show up larger and "+page.svelte" to be smaller as it's not that important. e.g.

/login

+page.svelte

The plugin would have to be able to understand how a sveltekit project could be structured.

Importance

nice to have

Additional Information

No response

ethanfox avatar Dec 19 '22 23:12 ethanfox

you could try setting the short setting for labelFormat: https://stackoverflow.com/questions/54354775/visual-studio-code-how-do-i-display-the-file-directory-in-the-tab-for-all-files#54354948

VS Code does not expose an API to allow to to handle this in the Svelte VS Code plugin: https://github.com/microsoft/vscode/issues/41909

benmccann avatar Dec 20 '22 00:12 benmccann

you could try setting the short or medium setting for labelFormat: https://stackoverflow.com/questions/54354775/visual-studio-code-how-do-i-display-the-file-directory-in-the-tab-for-all-files#54354948

VS Code does not expose an API to allow to to handle this in the Svelte VS Code plugin

Tragic. Just thought it would be cool to have. Not a big deal.

ethanfox avatar Dec 20 '22 00:12 ethanfox

Labeling this as 'documentation' so that we can mention the workbench.editor.labelFormat setting somewhere, possibly in https://kit.svelte.dev/docs/creating-a-project#editor-setup

Conduitry avatar Dec 20 '22 00:12 Conduitry

There's a new workbench.editor.customLabels.patterns setting that can be used. We should perhaps wait until it hits stable to document it, but I'd love to get feedback on it: https://twitter.com/BenjaminMcCann/status/1770847155739144487

benmccann avatar Mar 21 '24 17:03 benmccann

Do we still need to document this if we can include it by default when the Svelte VS Code extension is installed? https://github.com/sveltejs/language-tools/pull/2330

eltigerchino avatar Apr 05 '24 09:04 eltigerchino