user-event
user-event copied to clipboard
Update `14.4.3 -> 14.5.0` causes error `TS1005: ',' expected`
Reproduction example
https://github.com/taiga-family/maskito/pull/507 https://github.com/taiga-family/maskito/pull/518
Actual behavior
See https://github.com/taiga-family/maskito/actions/runs/6189000924/job/16802149821?pr=507
Error: node_modules/@testing-library/user-event/dist/types/clipboard/copy.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/clipboard/cut.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/clipboard/paste.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/convenience/click.d.ts(1,[15](https://github.com/taiga-family/maskito/actions/runs/6189000924/job/16802149821?pr=507#step:4:16)): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/convenience/hover.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/convenience/tab.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/event/dispatchEvent.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/event/input.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/event/selection/index.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/event/selection/modifySelectionPerMouse.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/event/selection/setSelectionPerMouse.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/index.d.ts(6,40): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/keyboard/index.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/options.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/options.d.ts(2,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/pointer/index.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/pointer/index.d.ts(2,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/pointer/index.d.ts(3,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/setup/directApi.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/setup/directApi.d.ts(2,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/setup/directApi.d.ts(3,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/setup/directApi.d.ts(4,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/system/keyboard.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/system/keyboard.d.ts(2,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/system/pointer/buttons.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/utility/clear.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/utility/selectOptions.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/utility/type.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/utility/type.d.ts(2,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/utility/upload.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/utils/misc/level.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/utils/misc/wait.d.ts(1,15): error TS1005: ',' expected.
Error: node_modules/@testing-library/user-event/dist/types/utils/pointer/cssPointerEvents.d.ts(1,15): error TS1005: ',' expected.
Error: Process completed with exit code 2.
User-event version
14.5.0
Environment
No response
Additional context
No response
import {type Options} from "...'
were added in 14.5.0, this requires at least Typescript 4.5.0, otherwise it does not recognise the type
parameter as a token and tries to import it. https://www.typescriptlang.org/docs/handbook/release-notes/typescript-4-5.html#type-modifiers-on-import-names
Your project probably uses an older version of typescript.