Skip to content

error TS4058 caused by RawSymbol #7048

@RomainLanz

Description

@RomainLanz

Vue version

3.2.41

Link to minimal reproduction

https://stackblitz.com/edit/vitejs-vite-f88icu?file=src/use-foo.ts

Steps to reproduce

Note: Similar to #2548

  1. Create a project using TypeScript and Vue 3
  2. Use the @vue/tsconfig config
  3. Create a composable with markRaw
export function useFoo() {
  return markRaw({ foo: 'bar' })
}

What is expected?

TypeScript should be happy

What is actually happening?

TypeScript raises an error.

TS4058: Return type of exported function has or is using name 'RawSymbol' from external module "~/workspace/node_modules/.pnpm/@vue+reactivity@3.2.41/node_modules/@vue/reactivity/dist/reactivity" but cannot be named.

System Info

No response

Any additional comments?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    🍰 p2-nice-to-havePriority 2: this is not breaking anything but nice to have it addressed.has PRA pull request has already been submitted to solve the issuescope: types

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions