Hello, I am trying to embed Microsoft Power Automate into my webApp, I'm a pretty new developer and have already tried doing the steps listed on the official documentation. I set up the link to "https://flow.microsoft.com/Content/msflowsdk-1.1.js" in my index.html file and it seems to be loading, but when trying to compile, it gives me a ReferenceError: MsFlowSdk is not defined. How can I fix this? Here is the code I'm using with ReactJS:
import React, {Fragment, useState} from 'react'; import SideNavAutomatizar from './SideNavAutomatizar'; import './limites.css'; export default function Automatizar() { /*global MsFlowSdk*/ var sdk = new MsFlowSdk({ hostName:'https://flow.microsoft.com', locale:'es-es' }); window.msFlowSdkLoaded = function(){ var sdk = new MsFlowSdk({ hostName: 'https://flow.microsoft.com/'}); var widget = sdk.renderWidget('templates', { container: 'flowDiv'}); } return (
<div id="flowDiv" class="flowContainer"></div>
) }