Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

117
Views
How do I put this google dialogflow code into a typescript react app?

Google Dialog flow has this code snippet for integrating your chatbot into an html page.

<script src="https://www.gstatic.com/dialogflow-console/fast/messenger/bootstrap.js?v=1"></script>
<df-messenger
  intent="WELCOME"
  chat-title="FirstTest"
  agent-id="xxxxxxxxxxx"
  language-code="en"
></df-messenger>

I feel like this should easily be implemented similarly to how you can implements aws kendra component into a tsx file like this

<Search
        kendra={kendra}
        s3={s3}
        indexId={indexId}
        facetConfiguration={facetConfiguration}
        />

This works but the google dialog flow snippet doesn't work.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Try adding the script in application's head tag

<script src="https://www.gstatic.com/dialogflow-console/fast/messenger/bootstrap.js?v=1"></script>

Then, use react's dangerouslySetInnerHTML prop

<div dangerouslySetInnerHTML={{ __html: `
   <df-messenger
     intent="WELCOME"
     chat-title="FirstTest"
     agent-id="xxxxxxxxxxx"
     language-code="en">
   </df-messenger>
` }} />
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!