The last time I encountered this error while trying to install react native on macos computer with terminal. What should I do? The error I get is as written in the picture. Do I need to change the package name? why did it give this error? help please**
I just started using android studio so I was afraid of doing something wrong. However, previous transactions were successful. I didn't expect to get this error at last.

Because you have two
package.jsonfile in your project,package.jsonand anothermyfirstRNapp/package.jsonin a sub directory.All information are on your terminal and it contains the path:
All you have to do is delete the duplicated file in the sub directory
myfirstRNapp. Don't delete the Main file !