Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
kakkaroolari
Frequent Visitor

How to add external javascript src=blocks to custom visual iframe

I'm developing a custom visual based on the Circle card example here:

https://github.com/microsoft/PowerBI-visuals-circlecard

 

Now, I'm using an external lib from npm that has an run time "dependency" to another .js lib that is supposed to be loaded thru https.

 

I need the following HTML element to appear inside my visuals sandbox iframe

 

<script src="https://taa.dii.da.daa/<external.js>" />

 

How can I do that?

 

Puttings it to the pbiviz.json externalJs did not work. Or do I, in addition to that import it in the visual.ts somehow?

 

This <external.js> file is not in npm, and the licence dictates that it shall not be downloaded and used locally as a copy.

2 REPLIES 2
waseemabbas19
Frequent Visitor

I want to call the nivo react chart library in the powerbi react visual. I also have seen the documentation. there, they said, you can't call the external js file in the powerbi api 3.0. or above. Any of the way to use react chart library with the latest powerbi library. Thanks

kakkaroolari
Frequent Visitor

Pop-up.

Is it true that nobody knows how to do this? Is there any other place people can ask these things?

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.