I have a component in a .js file which I have exported as default. I am trying to include this component in another .js file. I have also imported this component in the other file. I have tried using <componentName /> but this does not seem to work, it compiles and shows no error but nothing shows up. Any ideas?
2 Answers
First of all, as you are saying you are using it like <componentName />, this won't work, you should try renaming it with all caps ie. <ComponentName />. This is just an assumption. If the issue persists, please share the code, so that we can help you in a better way.
Discussion can be found here.
<componentName />, this won't work, you should try renaming it with all caps ie<ComponentName />. Please share the code so that we can help you. This is just an assumption.