Duplicates
Latest version
Current behavior 😯
Inside files in /routes that have a default export - ie those that export a route component - the imports that would usually be provided by unplugin-auto-import are (i assume) not present, so instead of rendering the icons there is an attempt to render undefined.
In files that don't export a default component this is apparently not an issue.
Expected behavior 🤔
The imports from unplugin-auto-import should always be present so that auto-imports can be used in route files.
Steps to reproduce 🕹
Steps:
- Go to this StackBlitz
- Notice that using the icon works in
/app.tsx and /routes/SeparateFileComponent.tsx, but not /routes/index.tsx
Context 🔦
I want to have auto imported icons throughout my whole app.
Your environment 🌎
No response
Duplicates
Latest version
Current behavior 😯
Inside files in
/routesthat have a default export - ie those that export a route component - the imports that would usually be provided byunplugin-auto-importare (i assume) not present, so instead of rendering the icons there is an attempt to renderundefined.In files that don't export a default component this is apparently not an issue.
Expected behavior 🤔
The imports from
unplugin-auto-importshould always be present so that auto-imports can be used in route files.Steps to reproduce 🕹
Steps:
/app.tsxand/routes/SeparateFileComponent.tsx, but not/routes/index.tsxContext 🔦
I want to have auto imported icons throughout my whole app.
Your environment 🌎
No response