npm eslint-plugin-react-refresh 0.4.0
v0.4.0

latest releases: 0.5.3, 0.5.2, 0.5.1...
3 years ago

Add allowConstantExport option (fixes #8)

This option allow to don't warn when a constant (string, number, boolean, templateLiteral) is exported aside one or more components.

This should be enabled if the fast refresh implementation correctly handles this case (HMR when the constant doesn't change, propagate update to importers when the constant changes). Vite supports it, PR welcome if you notice other integrations works well.

Allow all-uppercase function exports (fixes #11)

This only works when using direct export. So this pattern doesn't warn anymore:

export const CMS = () => <></>;

But this one will still warn:

const CMS = () => <></>;
export default CMS;

Don't miss a new eslint-plugin-react-refresh release

NewReleases is sending notifications on new releases.