How can i receuive webcontents event


i use electron to wrap a website, i want to open all window maximize, i listen the webview’s new-window event,i can receive the a link event, then i create a browerwindow and maximize it, but i can’t receive event the window open by script, like js, i have another trouble is some window open by a post method, i receive the new-window event but i can’t decide whether is post, i create browerwindow to open it,but the parameter all can i do it? is any way to maximize the window just set some option? when i didn’t hand new-window event open window with post data is work well,but requirement is to maximize it.