biofriction-wp-theme/node_modules/webpack/lib/serialization/DateObjectSerializer.js

17 lines
268 B
JavaScript
Raw Normal View History

2021-10-26 14:18:09 +02:00
/*
MIT License http://www.opensource.org/licenses/mit-license.php
*/
"use strict";
class DateObjectSerializer {
serialize(obj, { write }) {
write(obj.getTime());
}
deserialize({ read }) {
return new Date(read());
}
}
module.exports = DateObjectSerializer;