VMware Cloud Community
Jack22260126
Contributor
Contributor

Is this the limitation for angular2 plug-in?

I am implementing a plug-in for vSphere. However, I encounter a problem.

I use the Angular2 JS to implement my plug-in.

It was working very well in my local site, but after I registered it on vSphere, vSphere will open my plug-in slowly.

Especially, when the vSphere use navigator to load my page and open the global dialog(by WEB_PLATEFORM API).

I discuss this with my friend.

We think this is because of reloading angular2.

In my local site, I only need load it once and everything will work well (open dialog or navigate new page).

However, vSphere open plug-in global dialog and navigate page by using "iframe", and it will make it like open the web like first time (load all angular2 code).

ex1. navigate: close original one -> load another one (anglar2JS reload ).

ex2. open global dialog (load again), if i open twice, and then load x 2. (I tried their(navigator page and global dialog) variables cannot be shared, so they are independent angular2JS code)

These make it navigating and opening global dialog slowly every time.

Therefore, I hope someone could help me for this? How to improve it? Or this is just a limitation for vSphere?

0 Kudos
1 Reply
pwilk
Hot Shot
Hot Shot

This is not a limitation of vSphere. This behavior is caused by iframe. You'd need to consider a different way of handling your plug-in to improve its performance.

Cheers,

Paul Wilk

Cheers, Paul Wilk
0 Kudos