react-tooltip: ESLint warning: Package subpath './dist/react-tooltip' is not defined
Describe the bug When importing:
import 'react-tooltip/dist/react-tooltip.css';
I see the following error through eslint:
Resolve error: Package subpath './dist/react-tooltip' is not defined by "exports" in /Users/[username]/Sites/[projectname]/node_modules/react-tooltip/package.json
I’m not sure exactly where ‘./dist/react-tooltip’ is being requested (not in my codebase), but adding this to the react-tooltip package exports
resolves it:
"exports": {
...
"./dist/react-tooltip": "./dist/react-tooltip.cjs.js"
},
Version of Package v5.10.1-beta.4
About this issue
- Original URL
- State: closed
- Created a year ago
- Comments: 17 (9 by maintainers)
This fixes it, yes.