@neo-one/smart-contract-compiler
Version:
NEO•ONE TypeScript smart contract compiler.
14 lines (12 loc) • 328 B
JavaScript
let id = 0;
const getID = (type) => {
const typeAny = type;
if (typeAny.id == undefined && typeAny.__id === undefined) {
id += 1;
typeAny.__id = id;
return id;
}
return typeAny.id || typeAny.__id;
};
export const typeKey = (type) => `${getID(type)}`;
//# sourceMappingURL=typeKey.js.map