Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MultiWindowService(): uniqueName _gl__PluginURLProvider already taken by function PluginURLProvider() #79

Open
trajnisz opened this issue Mar 1, 2021 · 0 comments

Comments

@trajnisz
Copy link

trajnisz commented Mar 1, 2021

Versions:
"golden-layout": "^1.5.9",
"ngx-golden-layout": "0.0.37",
"@angular/cli": "^9.1.12",

Hi!
I have a problem with MultiWindowService. My Angular app structure is like this:

  • A: my own NPM package which is an Angular module (with component that uses GL and service) with
    imports: [ ... GoldenLayoutModule ]
    (no .forRoot(componentTypes) because i'm not using any declared component)

  • B: Angular app with 2 lazy modules. Let's say their names are B1, B2.

    • B1 is a module that imports A and uses its component
    • B2 is a module that uses GL in it's own components and
      imports: [ ... GoldenLayoutModule.forRoot(componentTypes), ]

When i open app and navigate to B1 or B2 everything works fine. Problem appears when i open one of them and later navigate to the other one. The error is:
Error: MultiWindowService(): uniqueName _gl__PluginURLProvider already taken by function PluginURLProvider() ... at ngx-golden-layout.js:59.
It seems like GL wants to initialize something that is already initialized. I don't know if i'm doing something wrong or it is a bug. Maybe app structure is bad but i don't know how to solve this... Has anyone had such a problem?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant