2 Object.defineProperty(exports, "__esModule", { value: true });
3 exports.RuleCreator = void 0;
4 const applyDefault_1 = require("./applyDefault");
5 function RuleCreator(urlCreator) {
6 // This function will get much easier to call when this is merged https://github.com/Microsoft/TypeScript/pull/26349
7 // TODO - when the above PR lands; add type checking for the context.report `data` property
8 return function createRule({ name, meta, defaultOptions, create, }) {
10 meta: Object.assign(Object.assign({}, meta), { docs: Object.assign(Object.assign({}, meta.docs), { url: urlCreator(name) }) }),
12 const optionsWithDefault = applyDefault_1.applyDefault(defaultOptions, context.options);
13 return create(context, optionsWithDefault);
18 exports.RuleCreator = RuleCreator;
19 //# sourceMappingURL=RuleCreator.js.map