UNPKG

nucleus-ui-builder

Version:
36 lines (35 loc) 847 B
function _define_property(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; } class CommandSchemaBuilder { addPositional(name, config) { this.schema.positional[name] = config; return this; } addOption(name, config) { this.schema.options[name] = config; return this; } build() { return this.schema; } constructor(schema = { positional: {}, options: {} }){ _define_property(this, "schema", void 0); this.schema = schema; } } export { CommandSchemaBuilder as default }; //# sourceMappingURL=command.schema.builder.js.map