Answer the question
In order to leave comments, you need to log in
Importing a component in React. Why does not it work?
Hello. Started learning React recently, in the process the following question appeared.
I'm building with create react app, then I want to split all the code into components. That's just the problem. When using import and export everything breaks. Could there be a reason in babel? How can I check what's wrong and fix the situation?
Thank you.
Answer the question
In order to leave comments, you need to log in
So you don't import it anywhere, writeimport {Footer} from './footer/footer.js'
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question