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

New window #767

Closed
pragasam1016 opened this issue Aug 2, 2023 · 1 comment
Closed

New window #767

pragasam1016 opened this issue Aug 2, 2023 · 1 comment

Comments

@pragasam1016
Copy link

pragasam1016 commented Aug 2, 2023

I have to open new popup window to get some user input.

openPopup(){
window.open(${window.location.href}/popup/)
}

This is available in the angular app. popup is the new component in the angular

It is working good in the local environment. The electron is creating new window and it is loading the html controllers in the new popup.
It is taking a path of http://localhost:4200/popup

when we take a build and install it OR if we stop localhost in the local environment it is not working. It looks for the file system path like file://C:/.. that which is not fine

Expectation :

I am looking for a solution where i can open popup angular component as a popup window in electron js.

@maximegris
Copy link
Owner

I would suggest you to read this official article about opening windows from the renderer

https://www.electronjs.org/docs/latest/api/window-open

By the way I would suggest you to use directly dialog/pop-in with Angular (for a better UX)

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

2 participants