Restrict imports, keeping your codebase clean and tailored. Test case: Avoid mistakenly using of useTranslation hook when you have useCustomTranslation.
Installation and usage:
"plugins": [
"restricts"
]
rules: {
'restricts/imports-of': [
'error',
{
// To disallow multiple imports, add them to the list, like ['useTranslation', 'useDispatch', 'anotherImport'].
disallowedImports: ['useTranslation'],
},
],
}