diff --git a/.prettierrc b/.prettierrc index c9afdc8d..db4ac60e 100644 --- a/.prettierrc +++ b/.prettierrc @@ -16,5 +16,15 @@ "singleQuote": true, "tabWidth": 2, "trailingComma": "all", - "useTabs": true -} + "useTabs": true, + "overrides": [ + { + "files": [ + "**/*.json" + ], + "options": { + "useTabs": false + } + } + ] +} \ No newline at end of file diff --git a/examples/resetting-via-key-prop/index.tsx b/examples/resetting-via-key-prop/index.tsx index 7aa9037a..7cbce8b4 100644 --- a/examples/resetting-via-key-prop/index.tsx +++ b/examples/resetting-via-key-prop/index.tsx @@ -4,7 +4,7 @@ import * as React from 'react' import * as ReactDOM from 'react-dom/client' -import { Switch } from '~/shared/switch' +import { Switch } from '~/shared/switch.tsx' function callAll>( ...fns: Array<((...args: Args) => unknown) | undefined> diff --git a/exercises/01.latest-ref/01.solution/increments.test.tsx b/exercises/01.latest-ref/01.solution/increments.test.tsx index fbd4d87f..e7b324b2 100644 --- a/exercises/01.latest-ref/01.solution/increments.test.tsx +++ b/exercises/01.latest-ref/01.solution/increments.test.tsx @@ -1,5 +1,5 @@ import { waitFor, within } from '@testing-library/dom' -import userEvent from '@testing-library/user-event' +import { userEvent } from '~/shared/user-event.cjs' import { expect, testStep } from '@kentcdodds/workshop-app/test' import '.' diff --git a/exercises/01.latest-ref/01.solution/step-change.test.tsx b/exercises/01.latest-ref/01.solution/step-change.test.tsx index 1460f44e..68595af6 100644 --- a/exercises/01.latest-ref/01.solution/step-change.test.tsx +++ b/exercises/01.latest-ref/01.solution/step-change.test.tsx @@ -1,5 +1,5 @@ import { waitFor, within, fireEvent } from '@testing-library/dom' -import userEvent from '@testing-library/user-event' +import { userEvent } from '~/shared/user-event.cjs' import { expect, testStep } from '@kentcdodds/workshop-app/test' import '.' diff --git a/exercises/02.composition/01.problem/index.tsx b/exercises/02.composition/01.problem/index.tsx index c88d5188..69348151 100644 --- a/exercises/02.composition/01.problem/index.tsx +++ b/exercises/02.composition/01.problem/index.tsx @@ -1,7 +1,7 @@ import * as React from 'react' import * as ReactDOM from 'react-dom/client' -import { allPokemon, PokemonDataView } from '~/shared/pokemon' -import type { PokemonData, User } from '~/shared/types' +import { allPokemon, PokemonDataView } from '~/shared/pokemon.tsx' +import type { PokemonData, User } from '~/shared/types.tsx' function App() { const [user] = React.useState({ name: 'Kody', image: '/img/kody.png' }) @@ -22,7 +22,7 @@ function App() { */}