From ad51d6280ddd543a9bece732b8230439f6e258e8 Mon Sep 17 00:00:00 2001 From: Rudolph Gottesheim Date: Mon, 22 Jul 2019 18:14:55 +0200 Subject: [PATCH] Docs: remove note about TypeScript files requiring at least one export (#7260) --- docusaurus/docs/running-tests.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/docusaurus/docs/running-tests.md b/docusaurus/docs/running-tests.md index e166c71dfd0..e33a4bf27f2 100644 --- a/docusaurus/docs/running-tests.md +++ b/docusaurus/docs/running-tests.md @@ -111,8 +111,6 @@ import Adapter from 'enzyme-adapter-react-16'; configure({ adapter: new Adapter() }); ``` -> Note: When using TypeScript with Babel, all your files need to have at least one export, otherwise you will get the error `Cannot compile namespaces when the '--isolatedModules' flag is provided.`. To fix this, you can add `export default undefined` to `src/setupTests.ts`. - > Note: Keep in mind that if you decide to "eject" before creating `src/setupTests.js`, the resulting `package.json` file won't contain any reference to it. [Read here](#initializing-test-environment) to learn how to add this after ejecting. Now you can write a smoke test with it: