From fa42a7469715c01ecf849a8255694709f3e9bfc3 Mon Sep 17 00:00:00 2001 From: jcoffey <51408202+jcoffey-dev@users.noreply.github.com> Date: Sun, 20 Sep 2026 16:08:17 -0700 Subject: [PATCH] Take the lint error out of main (#6) `npm run lint` fails on main, and has since CI was added, so every pull request opened against it starts red for a reason that has nothing to do with the change in it. Two unrelated PRs came back with the same failure, which is how it was found. vite.config.ts 1:1 error Do not use a triple slash reference for vitest/config, use `import` style instead The reference was doing one job: putting the `test` key in scope for defineConfig. Importing defineConfig from vitest/config rather than vite does the same job in the style the rule asks for, and the file already imported configDefaults from there on the next line. --- vite.config.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/vite.config.ts b/vite.config.ts index 3ee60ba..a111d13 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -1,6 +1,7 @@ -/// -import { configDefaults } from 'vitest/config' -import { defineConfig } from 'vite' +// defineConfig comes from vitest/config rather than vite, which is what puts +// the `test` key below in scope. It replaces a triple-slash reference that did +// the same job and that eslint rejects. +import { configDefaults, defineConfig } from 'vitest/config' import react from '@vitejs/plugin-react' import tailwindcss from '@tailwindcss/vite' import path from 'path'