VSCode Extension: Failing to find config
See original GitHub issueHi friends. Thanks for all the work on this project so far.
I’m having some trouble with the VS Code extension and am hoping you can point me in the correct direction to troubleshoot from here.
Am I perhaps looking for the wrong config?
Error from Remote Extension Log
2022-11-12 11:36:51.740 [error] /home/mike/Development/solidstart/node_modules/.pnpm/vitefu@0.1.1_vite@3.2.3/node_modules/vitefu/src/index.js:8
const { createRequire } = (await Promise.resolve().then(() => require('module'))).default;
^^^^^^^
SyntaxError: Unexpected identifier
at new Script (node:vm:100:7)
at createScript (node:vm:257:10)
at Object.runInThisContext (node:vm:305:10)
at jiti2 (/home/mike/.vscode-server/extensions/antfu.unocss-0.45.21/dist/index.js:3613:48)
at /home/mike/Development/solidstart/node_modules/.pnpm/vite-plugin-solid@2.4.0_solid-js@1.6.2+vite@3.2.3/node_modules/vite-plugin-solid/dist/esm/index.mjs:8:15
at jiti2 (/home/mike/.vscode-server/extensions/antfu.unocss-0.45.21/dist/index.js:3618:15)
at /home/mike/Development/solidstart/node_modules/.pnpm/solid-start@0.2.5_3zrnixj5s2zo7r5ma456ac2ypm/node_modules/solid-start/vite/plugin.js:11:47
at jiti2 (/home/mike/.vscode-server/extensions/antfu.unocss-0.45.21/dist/index.js:3618:15)
at /home/mike/Development/solidstart/__unconfig_vite.config.ts:5:36
at jiti2 (/home/mike/.vscode-server/extensions/antfu.unocss-0.45.21/dist/index.js:3618:15)
at loadConfigFile (/home/mike/.vscode-server/extensions/antfu.unocss-0.45.21/dist/index.js:63449:11)
at async Object.load (/home/mike/.vscode-server/extensions/antfu.unocss-0.45.21/dist/index.js:63381:24)
at async loadConfig (/home/mike/.vscode-server/extensions/antfu.unocss-0.45.21/dist/index.js:63511:18)
at async reloadConfig (/home/mike/.vscode-server/extensions/antfu.unocss-0.45.21/dist/index.js:63537:20)
2022-11-12 11:36:51.774 [error] EntryNotFound (FileSystemError): Error: ENOENT: no such file or directory, stat '/home/mike/Development/solidstart/__unconfig_vite.config.ts'
at Function._handleError (/home/mike/.vscode-server/bin/6261075646f055b99068d3688932416f2346dd3b/out/vs/workbench/api/node/extensionHostProcess.js:94:29967)
at Object.stat (/home/mike/.vscode-server/bin/6261075646f055b99068d3688932416f2346dd3b/out/vs/workbench/api/node/extensionHostProcess.js:94:28335)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
2022-11-12 11:36:51.858 [error] EntryNotFound (FileSystemError): Error: ENOENT: no such file or directory, stat '/home/mike/Development/solidstart/__unconfig_vite.config.ts'
at Function._handleError (/home/mike/.vscode-server/bin/6261075646f055b99068d3688932416f2346dd3b/out/vs/workbench/api/node/extensionHostProcess.js:94:29967)
at Object.stat (/home/mike/.vscode-server/bin/6261075646f055b99068d3688932416f2346dd3b/out/vs/workbench/api/node/extensionHostProcess.js:94:28335)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
vite.config.ts
import solid from "solid-start/vite"
import { defineConfig } from "vite"
import presetUno from "unocss/preset-uno"
import UnoCSS from "unocss/vite"
import presetAttributify from "@unocss/preset-attributify"
import transformerDirectives from "@unocss/transformer-directives"
export default defineConfig({
plugins: [
solid(),
UnoCSS({
presets: [presetUno(), presetAttributify()],
transformers: [transformerDirectives()],
}),
],
})
Thanks for taking a look! Having a real blast using this so far, outside of the intellisense not working.
Issue Analytics
- State:
- Created 10 months ago
- Reactions:2
- Comments:13 (2 by maintainers)
Top Results From Across the Web
Extension is unable to find config file · Issue #535 - GitHub
However for some reason vsode throws up error saying it is unable to locate the file. While I can clearly access the file...
Read more >User and Workspace Settings - Visual Studio Code
In general, VS Code extensions store their settings in your user or workspaces settings files and they are available through the Settings editor...
Read more >Troubleshoot Terminal launch failures - Visual Studio Code
You can review settings in the Settings editor (File > Preferences > Settings) and search for specific settings by the setting ID.
Read more >Remote Development Tips and Tricks - Visual Studio Code
This article covers troubleshooting tips and tricks for each of the Visual Studio Code Remote Development extensions. See the SSH, Containers, ...
Read more >Settings Sync in Visual Studio Code
Settings Sync lets you share your Visual Studio Code configurations such as settings, keybindings, and installed extensions across your machines so you are ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
ye i mean it does work but it is obv a bug as its mentioned in the docs that uno config is not required (if you use vite, astro etc)
This worked for me too. But I’m curious why it doesn’t work with
vite.config.ts
, it’s mentioned in the docs