I searched Qwik and confirmed that there is no corresponding Issue.
Currently, there is no export of the Qwik type definition file in package.json.
This causes an error when configuring tsconfig.json according to the documentation, as it does not recognize the type definition file.
". /node_modules/unplugin-icons/types/qwik" will work properly, so it is almost certainly a misconfiguration in package.json.
If you add the following to the exports field in package.json, it should work correctly with the configuration as documented.
❯ npm run build
> vite-qwik@0.0.0 build
> tsc && vite build
error TS2688: Cannot find type definition file for 'unplugin-icons/types/qwik'.
The file is in the program because:
Entry point of type library 'unplugin-icons/types/qwik' specified in compilerOptions
tsconfig.json:24:15
24 "types": ["unplugin-icons/types/qwik"]
~~~~~~~~~~~~~~~~~~~~~~~~~~~
File is entry point of type library specified here.
Found 1 error.
Describe the bug
I searched Qwik and confirmed that there is no corresponding Issue.
Currently, there is no export of the Qwik type definition file in package.json. This causes an error when configuring
tsconfig.json
according to the documentation, as it does not recognize the type definition file.". /node_modules/unplugin-icons/types/qwik"
will work properly, so it is almost certainly a misconfiguration inpackage.json
.If you add the following to the
exports
field inpackage.json
, it should work correctly with the configuration as documented.Issue before submitting the PR.
Should I submit a PR on my end?
Rerated PR
https://github.com/unplugin/unplugin-icons/pull/262/files#diff-7ae45ad102eab3b6d7e7896acd08c427a9b25b346470d7bc6507b6481575d519
Reproduction
https://stackblitz.com/edit/vitejs-vite-uv7rug?file=package.json
System Info
Used Package Manager
npm
Validations