expo / expo/snack

App.js: Identifier 'React' has already been declared.

Open
#699 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
510
Forks
178
Avg merge
5h 7m
Merged PRs (30d)
5

Description

### Summary

**App.js: Identifier 'React' has already been declared** Error

I noticed in my iPhone expo app. There is only 1 line of

import React from 'react';

It seems to be duplicating the imports?

### What platform(s) does this occur on?

iOS

### SDK Version

55

### Reproducible demo or steps to reproduce from a blank project

Keep switching apps on IPhone, and when you go back to expo iOS app you get the error.

Contributor guide

Open the contributing guide

Research direction

Start with App.js and reproduce the issue by switching away from and back to the Expo iOS app on an iPhone. Check why the single React import is treated as duplicated; done means returning to the app no longer produces the identifier error.

Written by the indexing model from the issue text.

Assessment

Tech stack
react-native
Domain
mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.