eslint-plugin-flawless 0.1.10 → 0.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,5 @@
1
+ import { Plugin } from "@oxlint/plugins";
2
+ //#region src/oxlint.d.ts
3
+ declare const _default: Plugin;
4
+ //#endregion
5
+ export { _default as default };
@@ -0,0 +1,25 @@
1
+ import { n as plugin, t as PLUGIN_NAME } from "./plugin-DYVtpuio.mjs";
2
+ import { definePlugin } from "@oxlint/plugins";
3
+ //#region src/oxlint.ts
4
+ /**
5
+ * Oxlint `jsPlugins` entry point.
6
+ *
7
+ * Exposes only the dual-runtime rules — those authored with
8
+ * `createFlawlessRule`, identified by the presence of a `createOnce`
9
+ * method. Type-aware (`naming-convention`) and custom-parser (`toml-sort-keys`,
10
+ * `yaml-block-key-blank-lines`) rules are intentionally excluded: oxlint's JS
11
+ * plugin API supports neither TypeScript type information nor foreign parsers.
12
+ *
13
+ * The rule objects are shared verbatim with the ESLint plugin
14
+ * (`./plugin`); oxlint runs their `createOnce` method while ESLint runs the
15
+ * delegating `create`. `meta.name` stays `flawless`, so config keys match the
16
+ * ESLint prefix (e.g. `flawless/purity`).
17
+ */
18
+ const rules = {};
19
+ for (const [name, rule] of Object.entries(plugin.rules)) if ("createOnce" in rule) rules[name] = rule;
20
+ var oxlint_default = definePlugin({
21
+ meta: { name: PLUGIN_NAME },
22
+ rules
23
+ });
24
+ //#endregion
25
+ export { oxlint_default as default };