mawie81 / electron-window-state

A library to store and restore window sizes and positions for your Electron app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Specifying path param won't work

danivalls opened this issue · comments

Hello!

I'm trying to save the file into a specific path using the path property as the documentation says, but it won't work for me. windowStateKeeper keeps saving the file in the default path (app.getPath('userData')).

This is how I'm trying to do it:

let mainWindowState = windowStateKeeper({
  path: app.getPath('documents'),
  file: 'window-state-my-app.json',
  defaultWidth: 1000,
  defaultHeight: 600
})

I guess I'm probably doing something wrong, any idea what could it be?