A pure-JS adaptation of the W3C's Structured Cloning Algorithm