Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

renderWebChat not working in Angular #5435

Open
sreeraj05 opened this issue Feb 27, 2025 · 2 comments
Open

renderWebChat not working in Angular #5435

sreeraj05 opened this issue Feb 27, 2025 · 2 comments
Labels
Bot Services Required for internal Azure reporting. Do not delete. Do not change color. bug Indicates an unexpected problem or an unintended behavior. customer-reported Required for internal Azure reporting. Do not delete.

Comments

@sreeraj05
Copy link

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: Chrome (latest)

Which area does this issue affect?

Development experience

Which theme pack does this issue affect?

I did not test it on other theme packs

What is the public URL for the website?

No response

Please describe the bug

i am getting ERROR TypeError: import_react_dom2.default.render is not a function . i am using latest bot framework and angular

Do you see any errors in console log?

app.component.ts:77 ERROR TypeError: import_react_dom2.default.render is not a function
    at _AppComponent.<anonymous> (app.component.ts:156:21)
    at Generator.next (<anonymous>)
    at fulfilled (main.js:5:24)
Promise.then		
(anonymous)	@	app.component.ts:77
(anonymous)	@	main.js:18
__async	@	main.js:2
InitDirectLine	@	app.component.ts:57
ngOnInit	@	app.component.ts:39
Zone - Promise.then		
(anonymous)	@	main.ts:5


"botframework-webchat": "^4.18.0",

"@angular/core": "^19.1.0",

How to reproduce the issue?

WebChat.renderWebChat({
directLine: directLine,
}, document.getElementById('webchat'));

What do you expect?

it should work

What actually happened?

ERROR TypeError: import_react_dom2.default.render is not a function
at f3 (chunk-6NGHWPUW.mjs:118:5)
at _AppComponent. (app.component.ts:156:21)
at Generator.next ()
at fulfilled (main.js:5:24)
at _ZoneDelegate.invoke (zone.js:369:28)
at Object.onInvoke (core.mjs:6525:25)
at _ZoneDelegate.invoke (zone.js:368:34)
at ZoneImpl.run (zone.js:111:43)
at zone.js:2538:40

Do you have any screenshots or recordings to repro the issue?

No response

Adaptive Card JSON

Additional context

No response

@sreeraj05 sreeraj05 added Bot Services Required for internal Azure reporting. Do not delete. Do not change color. bug Indicates an unexpected problem or an unintended behavior. customer-reported Required for internal Azure reporting. Do not delete. labels Feb 27, 2025
@sreeraj05
Copy link
Author

No description provided.

@OEvgeny
Copy link
Collaborator

OEvgeny commented Feb 27, 2025

I've got this example with Angular working: https://stackblitz.com/edit/bfcweb-chat-fluent-angular.

The issue seems to appear due to the React and ReactDOM versions used. Which particular versions of the packages you have installed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bot Services Required for internal Azure reporting. Do not delete. Do not change color. bug Indicates an unexpected problem or an unintended behavior. customer-reported Required for internal Azure reporting. Do not delete.
Projects
None yet
Development

No branches or pull requests

2 participants