I am working on a NextJs app and I have a header folder with a Header.jsx and a default export Header
.
In the same folder I have a index.js
with this code
export * from './Header'
but if I use it, it fails with an error
Attempted import error: '../components/header' does not contain a default export (imported as 'Header').
If I use this
import Header from './Header'
export default Header
It works fine. is there a way, in NextJs to use the single line export avoiding this repetition?
Thanks