feat(algorithms): allow calling with a PermissionName #115
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Instead of forcing specs for simple permissions to write out a permission
descriptor. This partially fixes @annevk's objection that writing
{name: "persistent-storage"}
in a spec doesn't formally create a WebIDL dictionary instance, although we'll still need to formalize syntax like that for more complicated descriptors.Preview at https://api.csswg.org/bikeshed/?url=https://raw.githubusercontent.com/jyasskin/permissions/permission-name-shorthand/index.bs#reading-current-states. I'm not sure the best place to define this. I want folks who click the link to, say, https://api.csswg.org/bikeshed/?url=https://raw.githubusercontent.com/jyasskin/permissions/permission-name-shorthand/index.bs#request-permission-to-use to find the definitions of the shorthands (so a separate "shorthands" section is out), and I don't want to make every spec write out
<a for="PermissionName">request permission to use</a>
to disambiguate the two definitions (so direct links to the shorthand are out). The wording doesn't fit well right next to the main definition, so I put it below.