refactor(core): add allowlist for window creation options
What kind of change does this PR introduce?
- [ ] Bugfix
- [ ] Feature
- [ ] Docs
- [ ] New Binding issue #___
- [ ] Code style update
- [x] Refactor
- [ ] Build-related changes
- [ ] Other, please describe:
Does this PR introduce a breaking change?
- [ ] Yes, and the changes were approved in issue #___
- [ ] No
Checklist
- [ ] When resolving issues, they are referenced in the PR's title (e.g
fix: remove a typo, closes #___, #___) - [x] A change file is added if any packages will require a version bump due to this PR per the instructions in the readme.
- [ ] I have added a convincing reason for adding this feature, if necessary
Other information
Is it just me or is adding a flag for every single option is a little extreme?
This way everyone would probably just opt for "all": true again.
I was discussing that with @tweidinger
Is it just me or is adding a flag for every single option is a little extreme?
This way everyone would probably just opt for
"all": trueagain.
Yep, this is not an ideal solution but better than the current state (where every additional window could possibly be abused for things like global clipboard access without honoring the main window permissions). I also mentioned that it could be nice to add a flag for permission inheritance, so it is possible to configure it but not necessarily needed.
My quote from the chat on this pr:
I think thats the straightforward way for it currently👍 Offtopic: It gets more interesting when thinking about window specific allowlists. Something like a toggle for allowlist inheritance
inheritWindowOptionsor allowlist templateswindowChildrenOptionscould be options in the future.