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.

Javascript API: Problem with BookmarksManager when Bootstrap API is used

Summary:
If a report used Bootstrap without specifying an embedUrl, the BookmarksManager will not work.

 

Detail:

According to the Bootstrap API documentation, the embedUrl is not a required property  ( https://github.com/microsoft/PowerBI-JavaScript/wiki/Bootstrap-For-Better-Performance#bootstrap-embe... ). So when I use this API, I don't specify the embedUrl because I don't know it at that moment and later I load the report using a complete embed configuration (so far everything works fine)

The BookmarksManager is initialized when the bootstrap process begins and at that moment it keeps a copy of the embeb configuration that does not have the embedUrl. The problem is that when the report is fully loaded using a complete embed configuration, the copy of the config that the BookmarksManager had is not updated. So when the BookmarksManager is used, it calls the isRDLEmbed function that does not check if the embedUrl is undefined and it will crash on the line "return embedUrl.toLowerCase().indexOf("/rdlembed?") >= 0"

 

Workaround:
For now I have specified an embedUrl ( "https://app.powerbi.com/reportEmbed" ) when bootstrapping, but I don't think that it's a good idea to hard-code that url in my program because I guess it could change in the future.

Status: New
Comments
v-yuta-msft
Community Support

@Norm ,

 

If this issue persists, I would suggest you create a support ticket here for further analysis.

Support Ticket.gif 

Regards,

Jimmy Tao