aleclarson / vite-tsconfig-paths

Support for TypeScript's path mapping in Vite
MIT License
1.35k stars 50 forks source link

cannot find `"@/containers-legacy/workorder/actions/kpiOrder/"` #40

Closed aladdin-add closed 3 years ago

aladdin-add commented 3 years ago

env:

vite@2.6.7
vite-tsconfig-paths@3.3.17
➜  honor git:(master) ✗ yarn vite --force
error when starting dev server:
Error: The following dependencies are imported but could not be resolved:

  @/containers-legacy/workorder/actions/kpiOrder/ (imported by /Users/weiran/repo/dian/honor/src/containers-legacy/workorder/pages/kpiOrder/index.jsx)

There is something like import actions from '@/containers-legacy/workorder/actions/kpiOrder/' in our codebase. it's working after removing the last /.

aleclarson commented 3 years ago

I can't reproduce it.

Please reproduce the issue in ./demo folder in this repository and open a PR 👍

aladdin-add commented 3 years ago

it turns out the kpiOrder is not a dir, but a file named kpiOrder.jsx. :-O

closing, as it is not a bug in the plugin. sorry for wasting ur time!