Overwrite default autosave settings in theia

I can see that autosave is disabled by default in theia from file menu autosave option. I would like to know how to overwrite the default false setting to true from the code. Tried overwriting the same from package.json like below. Still I can see the autosave is disabled
“preferences”: {
“editor.autoSave”: “on”

Hey @SParvathy,

for some versions of Theia now, the editor.autoSave property doesn’t accept on but only off, afterDelay, onFocusChange or onWindowChange. Note that every value except for off works exactly like the old on. We had to change this because of an upgrade of the monaco editor.

Okay thanks. Tried adding “editor.autoSave”: “afterDelay” then in the package.json. Still the autosave menu is not found enabled on app launch. But on clicking auto save menu from file, observed that “files.autoSave”: “afterDelay” is getting added in .theia/settings.json. So added the same in package.json and on app launch it is enabled.