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

Pass a request for user-initiated reload navigation #3586

Closed
wants to merge 2 commits into from

Conversation

yutakahirano
Copy link
Member

@yutakahirano yutakahirano commented Mar 22, 2018

This is a preliminary change to fix w3c/ServiceWorker#1167. I'm
planning to merge "reload-triggered navigation" flag in the navigation algorithm and
"reload-navigation" flag which I'm going to introduce on request, and as a preparation
this change lets the user-initiated reload navigation give a request as resource.


/acknowledgements.html ( diff )
/history.html ( diff )

@yutakahirano
Copy link
Member Author

@domenic, can you take a look?

This is a refactoring and I don't want to change the behavior.
I'm proposing this small change because I'm not familiar with this repository at all and I want to make sure my understanding of the spec is correct. Please correct me if I'm wrong.

Thanks!

@domenic
Copy link
Member

domenic commented Mar 22, 2018

I'm on vacation until April 1, but probably @annevk is a better reviewer for navigation anyway.

<span>active document</span>'s <span>reload override flag</span> is set, then the user agent may
instead perform <span>an overridden reload</span> rather than the navigation described in this
paragraph (with the <span>browsing context</span> being reloaded as the <span>source browsing
context</span>).</p>
Copy link
Member

Choose a reason for hiding this comment

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

This seems incorrect as it sets the request method to GET, whereas it could have been POST.

In general the layering here is very poor. We need to store the request method somewhere so that it can be reused in cases like this, but there's currently no explicit slot for that. Maybe a history entry is the right place.

I also think that in case you reload you probably just want to navigate to the current history entry in some way and not to a new request.

Copy link
Member Author

Choose a reason for hiding this comment

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

Hmm, probably I read the current spec sentence wrongly.

The intention here is "whatever resource used for the navigation to the active document, reuse it", right?

Copy link
Member

Choose a reason for hiding this comment

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

Yeah. Again, I agree it's a very sub par way of defining things.

@yutakahirano
Copy link
Member Author

Abandoning this PR...

@yutakahirano yutakahirano deleted the navigation-type branch March 27, 2018 05:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

Proposal: FetchEvent.navigationLoadType
3 participants