postlight / trimmings

🌲 Get back to HTML.
https://postlight.github.io/trimmings
Apache License 2.0
221 stars 8 forks source link

Configure default parameters for ajax requests #38

Open garygreen opened 4 years ago

garygreen commented 4 years ago

It would be great if we could configure the ajax/fetch requests to include additional information, a bit like axios config defaults

Our use case is that we want to add a custom header X-Requested-With-Trimmings that way we can detect this on the server and only serve partial HTML if we know we don't need to render the full page.