import React, { useState } from 'react' import ReactDOM from 'react-dom' import PowerBiEmbedded from '../src/index' type Props = { token: string; } // eslint-disable-next-line react/prop-types const Example: React.FC = ({token}) => { const [mobileVal, setMobileVal] = useState(false) const [widthValue, setWidthValue] = useState(400) return
{setWidthValue(+evt.target.value)}} value={widthValue}/> console.log('loaded!!!!!')} permissions={7} embedType="report" // eslint-disable-next-line max-len embedUrl="https://app.powerbi.com/reportEmbed?reportId=f6bfd646-b718-44dc-a378-b73e6b528204&groupId=be8908da-da25-452e-b220-163f52476cdd&config=eyJjbHVzdGVyVXJsIjoiaHR0cHM6Ly9XQUJJLVVTLU5PUlRILUNFTlRSQUwtcmVkaXJlY3QuYW5hbHlzaXMud2luZG93cy5uZXQiLCJlbWJlZEZlYXR1cmVzIjp7Im1vZGVybkVtYmVkIjp0cnVlfX0%3d" accessToken={token} />
} fetch('https://powerbiplaygroundbe.azurewebsites.net/api/Reports/SampleReport') .then(res => res.json()) .then((data) => { const token = data.embedToken.token ReactDOM.render( , document.getElementById('root') ) })