src/db.js
function serialize(input) {
    const value = JSON.stringify(input);
    return value === undefined
        ? reject(new Error(`Unsupported type ${type(input)}`))
        : resolve(value);
}
function serialize(input) {
    const value = JSON.stringify(input);
    return value === undefined
        ? reject(new Error(`Unsupported type ${type(input)}`))
        : resolve(value);
}
function serialize ( input ) { const value = JSON . stringify ( input ) ; return value === undefined ? reject ( new Error ( ` ${ type ( input ) } ` ) ) : resolve ( value ) ; }
Marshalls the JS input

@param {Mixed} input
@return {Promise}
Marshalls the JS input