JavaScript Selenium script: How to start my desktop electron app maximized or minimized?

Hello testing comunity i would like to ask if some one achieved to start there electron app maximized or minimized because i have tried everything by adding arguments for starting maximize when building the app and by using selenium driver.menage().window().maximize(). Is there any other solution?

The expectation was to maximize or minimize the desktop electron app.