An ESLint plugin that enforces namespace imports (import * as React from 'react') over named or default imports from the React package. Version 1.0.5 is current, with stable API since initial release. Key differentiator: focused solely on a single rule to enforce consistent React import style, unlike broader linting configs. Low maintenance frequency.
npm install eslint-plugin-react-namespace-importVerified import paths — ran on the pinned version, not inferred.
Install and configure the plugin to enforce namespace imports from React.
Only enforces namespace imports for 'react'; other packages ignored.
No fix available; rule name remains as is. Consider it as 'enforce-namespace-import' mentally.
Override rule severity in your own .eslintrc if you want errors.
Use another plugin if you need to enforce namespace imports for other packages.
Run npm install --save-dev eslint-plugin-react-namespace-import
Ensure plugin is in 'plugins' array, not 'extends', and rule name is correct.
Ensure eslint version >=0.8.0 and plugin is installed.