Skip to content

Conversation

@DrJest
Copy link

@DrJest DrJest commented Aug 14, 2018

Added an option to change request behaviour, allowing to add custom request headers, change request method and progress/abort callbacks
Had to change this to deal with Wordpress's admin-ajax which only accepts POST requests, maybe someone else could find it useful

DrJest added 2 commits August 14, 2018 08:15
Adding a request_options option to change request behaviour, allowing to add request headers, change request method and adding progress / abort callbacks
@DrJest DrJest changed the title Update page-load.js Update page-load.js - Adding some requeste options Aug 14, 2018
@DrJest DrJest changed the title Update page-load.js - Adding some requeste options Update page-load.js - Adding some request options Aug 14, 2018
@desandro
Copy link
Member

Thanks for opening this PR. I could see how this kind of feature would be useful.
Add a 👍 reaction to this issue if you would like to see this feature added. Do not add +1 comments — They will be deleted.

@calinrada
Copy link

Is the maintainer dead ?

@desandro
Copy link
Member

Infinite Scroll v4 has been released. Infinite Scroll v4 adds a new option, fetchOptions, which allows you to set method, headers, CORS mode, and other fetch options.

fetchOptions: {
  mode: 'cors',
  cache: 'no-cache',
  credentials: 'same-origin',
  headers: {
    'X-Session-Id': '33vscths658h7996d324rqft1s',
  },
},

Thank you for your original contribution. While I did not merge it in, your effort did help me decide to support the feature.

@desandro desandro closed this Jan 12, 2021
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.

3 participants