Skip to content

Commit

Permalink
chore: ignore TS error in config object
Browse files Browse the repository at this point in the history
Fixes #2483

The introduction of `idPrefix` in Vue's `AppConfig` object triggers a TS error that we can't really get rid of (see #2483 for a more detailled explanation).
  • Loading branch information
cexbrayat committed Aug 1, 2024
1 parent bffa73a commit 7cb5cd4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/createInstance.ts
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,8 @@ export function createInstance(
keyof Omit<AppConfig, 'isNativeTag'>,
any
][]) {
// TODO should be switched to a ts-expect-error once Vue 3.5 is used
// @ts-ignore https://github.com/vuejs/test-utils/issues/2483
app.config[k] = isObject(app.config[k])
? Object.assign(app.config[k]!, v)
: v
Expand All @@ -269,6 +271,7 @@ export function createInstance(
// provide any values passed via provides mounting option
if (global.provide) {
for (const key of Reflect.ownKeys(global.provide)) {
// TODO should be switched to a ts-expect-error
// @ts-ignore: https://github.com/microsoft/TypeScript/issues/1863
app.provide(key, global.provide[key])
}
Expand Down

0 comments on commit 7cb5cd4

Please sign in to comment.