vitest-react-native
vitest-react-native copied to clipboard
TypeError: jsxDEV is not a function
Shortest repro for me was just:
index.test.tsx
<div />;
I don't see anything suspicious in my configs. My vitest.config.ts:
import { defineConfig } from 'vitest/config';
import reactNative from 'vitest-react-native';
import react from '@vitejs/plugin-react';
export default defineConfig({
plugins: [reactNative(), react()],
});
My tsconfig.json:
{
"extends": "@tsconfig/react-native/tsconfig.json"
}
Setting compilerOptions.jsx to react, react-jsx, react-jsxdev doesn't seem to do the trick.
Removing react plugin from vitest.config.ts and adding import React from react';
appears to work, but is not an option.
Any ideas? 🤔