mohebifar / mohebifar/react-native-copilot

Nesting CopilotStep within a CopilotStep results in infinite loop

Open
#103 1 comment 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
2.4k
Forks
428
PR merge metrics
No merged PRs in 30d

Description

Current Behavior
Nest a CopilotStep with in a CopilotStep and it results in an infinite loop.

Input Code

        <CopilotStep name="shareBrightToday" order={1} text="Share your practice.  You can also invite a grownup to learn along with you!">
          <CopilotTouchableOpacity>
            <View>
              [...]
              <CopilotStep name="shareBrightToday" order={2} text="Share your practice.  You can also invite a grownup to learn along with you!">
                 <CopilotTouchableOpacity>
                    [...]
                 </copilottouchableopacity>
              </CopilotStep
            </View>
          </copilottouchableopacity>
        </CopilotStep

Expected behavior/code

No infinite loop

Environment

  • Device: iPhone 8 simulator
  • OS: iOS 12
  • react-native-copilot: 2.4.1
  • react-native: 0.55.4
  • react-native-svg: 6.3.1

Possible Solution

Additional context/Screenshots
Add any other context about the problem here. If applicable, add screenshots to help explain.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the nested CopilotStep example on the stated React Native environment, then trace the CopilotStep handling for nested children to identify where the loop begins. Done means nested CopilotStep components no longer produce an infinite loop.

Written by the indexing model from the issue text.

Assessment

Tech stack
react-native
Domain
mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.