microsoft / microsoft/BotFramework-WebChat
Directline webchat not working in React Strict Mode
Nobody has claimed this yet.
- Dominant language
- HTML
- Stars
- 1.8k
- Forks
- 1.6k
- Avg merge
- 22h 58m
- Merged PRs (30d)
- 2
Description
Is it an issue related to Adaptive Cards?
No
Is this an accessibility issue?
No
What version of Web Chat are you using?
Latest production
Which distribution are you using Web Chat from?
NPM
Which hosting environment does this issue primarily affect?
Web apps
Which browsers and platforms do the issue happened?
Browser: Edge (latest), Browser: Chrome (latest), Browser: Firefox (latest)
Which area does this issue affect?
Others or unrelated
What is the public URL for the website?
No response
Please describe the bug
Minimizable web chat example from samples is not working in React Strict Mode.
conversations API is getting cancelled
React Version: 18.2.0
NodeJS: 18.19.1
Do you see any errors in console log?
No response
How to reproduce the issue?
- Navigate to samples of webchat from this repo
- Go to minimizable-webchat sample
- Add React Strict Mode
- Install the node modules and start the application
- You will see conversations API getting cancelled.
What do you expect?
Bot should start and conversations API should succeed.
NOTE: Bot works if React Strict Mode is removed.
What actually happened?
Bot shows "connecting..." and not starting. (Attached screenshot for the same)
Do you have any screenshots or recordings to repro the issue?
Adaptive Card JSON
No response
Additional context
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the samples/minimizable-webchat sample and reproduce the issue after enabling React Strict Mode with React 18.2.0 and Node.js 18.19.1. Trace why the conversations API is cancelled during startup; done means the bot starts and the conversations API succeeds in the sample while Strict Mode remains enabled.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- node.js, react
- Domain
- frontend, web-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100