start function is not firing up the Copilot Steps

Aperta
#350 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
react-native, typescript
Ambito
mobile

Direzione di ricerca

Inizia dalla riga indicata in src/Components/Tabs/Schedule.tsx e segui il percorso useCopilot start/onLayout. Riproduci il comportamento su React Native 0.83.0 con newArchEnabled=true, confrontandolo con 0.77.3; il lavoro è completato quando start attiva in modo affidabile i passaggi e gli eventi di Copilot.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Current Behavior
Everything was working fine till I was at react-native: 0.77.3. As soon as I upgraded to react-native: 0.83.0, I start getting issue of copilot-Steps not appearing or appearing after a lot of time then expected. I fire up the copilot events at start so I use onLayout but when it didn't appear, I tried to fire those events using start function with a Pressable Button but that didn't worked either. Also I have newArchEnabled=true which is essential for my build. Trying Below to give you some glimpse of my code:

Input Code

const { start, copilotEvents } = useCopilot();  // start is ran using onLayout in main View
const [lastEvent, setLastEvent] = useState<string | null>(null);

useEffect(() => {
      copilotEvents.on("stepChange", (step) => {
        setLastEvent(`stepChange: ${step?.name}`);
      });
      copilotEvents.on("start", () => {
        setLastEvent(`start`);
      });
      copilotEvents.on("stop", () => {
        setLastEvent(`stop`);
        dispatch(updateLocalStorageInfo("Schedule_Walkthrough_Completed"))
        console.log("Steps Completed")
      });
    }, [copilotEvents]);

<View style={styles.mainStyle} 
              onLayout={() => {
                 setTimeout(() => {
                    start(); 
                  }, 2000);
               }}>
  • Repo link (1596th Line):
https://github.com/RAWLICK/Rescheduler-App/blob/main/src/Components/Tabs/Schedule.tsx

Expected behavior/code
start function should normally fire up the copilot events as it was working before

Environment

  • Device: [Realme P4x]
  • OS: [Android 15]
  • react-native-copilot: [3.3.3]
  • react-native: [0.83.0]
  • react-native-svg: [15.15.1]
Lingua principale
TypeScript
Stelle
2.4k
Fork
425
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di mohebifar/react-native-copilot

Tutte le issue di mohebifar/react-native-copilot

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.