Incorrect warning: Unused export with no option to suppress

A single file defines and exports 2 react stateless/functional components.  I'm incorrectly receiving a warning about the exports being unused.


import React from 'react';

function H1(props) {
return (
<h1 {...props}
//also incorrectly get a warning that is_cool is an unresolved variable
className={props.is_cool ? 'first' : 'second'}>

function DateTime() {
return (
<div>The date is now: {new Date().toLocaleString()}</div>

//incorrectly marked as 'Unused export'
export {H1, DateTime}

Clicking right arrow reveals NO WAY to suppress.  I'm forced to disable completely.  Also Fix all option does nothing.


This file uses the exports


import React from 'react';
import ReactDOM from 'react-dom';
import * as C from './components'; //H1 and DateTime ARE used

<div style={{padding: 30}}>
//H1 used
<C.H1 id={'heading' + 1}
title={'Very interesting stuff here.'}
content={'This is cool'}
style={{fontSize: 50, color: '#669', fontWeight: 'normal'}}
//DateTime used



Please sign in to leave a comment.