Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@mattesmohr
Copy link
Member

The sandbox attribute is actually an enumerated attribute. However, the unique aspect here is that the attribute also allows a list of values. Therefore the modifier should accept either an enum or a set of options.

/// Restrict everything
InlineFrame {}.sandbox()

/// Restrict everything but downloads
InlineFrame {}.sandbox(.allowDownloads)

/// Permit popups and forms
InlineFrame {}.sandbox([.allowPopups, .allowForms])

@mattesmohr mattesmohr marked this pull request as ready for review December 31, 2024 10:48
@mattesmohr mattesmohr merged commit 44b4722 into main Dec 31, 2024
1 check passed
@mattesmohr mattesmohr deleted the fix-sandbox-attribute branch December 31, 2024 10:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant