When importing the TypeScript interface ChalkInstance
from chalk
:
import { ChalkInstance } from "chalk";
eslint-plugin-unicorn
gives the following error:
/Users/leonzalion/projects/playground/chalk/test.ts
1:1 error Use default import for module `chalk` unicorn/import-style
✖ 1 problem (1 error, 0 warnings)
However, there is no default import for the ChalkInstance
type.
My guess is that it has something to do with the following lines in the chalk type definitions:
declare const chalk: ChalkInstance;
export default chalk;
Repro: https://github.com/leonzalion/unicorn-import-style-bug
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too