@calf/serializable
Version:
Serializable module of Calf framework.
18 lines (17 loc) • 504 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Timestamp = void 0;
// External modules
require("reflect-metadata");
// Symbols
var timestamp_symbol_1 = require("../symbols/timestamp.symbol");
/**
* Timestamp decorator
*/
function Timestamp() {
// Init timestamp
var timestamp = { isTimeStamped: true };
// Set metadata
return Reflect.metadata(timestamp_symbol_1.TIMESTAMP_METADATA_KEY, timestamp);
}
exports.Timestamp = Timestamp;