A simple promise-compatible "document ready" event handler with a few extra treats.
const ready =
If in a non-commonjs environment, just include the script. It will attach
document.ready for you.
The document.ready promise will preserve any values that you may be passing through the promise chain.
// Using ES2015 and window.fetch