Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update and rename lazyload.md to loading-frame-default-eager.md #293

Merged
merged 5 commits into from
Apr 25, 2019

Conversation

ehsan-karamad
Copy link
Contributor

The policy is renamed accordingly.


The `loading-frame-default-eager` policy-controlled feature can be used for a main frame or a nested
`<iframe>` to overwrite the default or assigned value of the newly
introduced `loading` [attribute](https://github.com/whatwg/html/pull/3752) for `<iframe>` and `<img>`.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

... and <img>? Weren't we discussing a separate policy for images?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This part defines what loading attribute is; which is related to both <img> and <iframe>.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We shouldn't need to explain loading -- this feels like it should be the introduction to loading-frame-default-eager, so I parsed it incorrectly as "feature can be used ... to overwrite the default value ... for <iframe> and <img>"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Newest version does not name <img>.

policies/loading-frame-default-eager.md Outdated Show resolved Hide resolved
policies/loading-frame-default-eager.md Show resolved Hide resolved
Addressing clelland@'s comments.
Remove <img> reference.

The Extra Mile
-----------
In general the feature could allow an expanded set of enforcement policies with the use of [parametric features](https://github.com/WICG/feature-policy/issues/163). Under a geralized `loading-frame` policy, the following potential values could be supported (in the order of permissiveness):
Copy link
Contributor

@Malvoz Malvoz Apr 24, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

geralized

"generalized"?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. Thanks.

```HTTP
Feature-Policy: loading-frame-default-eager 'none'
```
would cause all the nested `<iframe>`'s and the corresponding nested and auxiliary browsing contexts to load lazily, unless the have specifically set `loading="eager"`. For example, if the document has
Copy link
Contributor

@Malvoz Malvoz Apr 24, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unless the have specifically set loading="eager"

"unless they have specifically set loading="eager""?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Malvoz added a commit to Malvoz/feature-policy that referenced this pull request Apr 24, 2019
Reflect the changes (to be merged) in w3c#293.
------------
With the `loading-frame-default-eager` attribute, developers could prioritize the loading of different inline frames on a web page. This however could become a cumbersome process and not quite scalable for larger
web sites specially given that applying the attribute is origin-agnostic. The proposed policy aims to resolve
this issue but changing a browser's default decision for `loading` behavior.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The proposed policy aims to resolve
this issue but changing a browser's default decision

"by changing a browser's..."?

Copy link
Contributor

@Malvoz Malvoz Apr 24, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done thanks. and yes it should definitely be sharing the same typos which I will tend to tomorrow.

Minor changes and typo fixes
@clelland clelland merged commit bc5484b into w3c:master Apr 25, 2019
clelland pushed a commit that referenced this pull request Apr 25, 2019
* Change 'lazyload' to 'loading-frame-default-eager'

Reflect the changes (to be merged) in #293.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants