glosslint 0.0.1 → 0.1.1

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.
package/dist/eslint.d.mts CHANGED
@@ -1,9 +1,11 @@
1
- import { c as Corpus, h as KindOf } from "./types-CBQGgzID.mjs";
1
+ import { c as Corpus, h as KindOf } from "./types-Bbp_cYfZ.mjs";
2
2
  import { Linter } from "eslint";
3
3
  /** Options of the ESLint config. */
4
4
  export interface GlosslintEslintOptions {
5
- /** The corpus, usually `import corpus from './glosslint.config.ts'`. */
6
- corpus: Corpus;
5
+ /** The glossary file to read instead of `.agents/glossary.md`. A string resolves from the current folder. */
6
+ glossary?: string | URL;
7
+ /** A corpus to use instead of a glossary file, such as `defineCorpus({ extends: [fromGlossary()], … })`. */
8
+ corpus?: Corpus;
7
9
  /** Files the rules run on. */
8
10
  files?: string[];
9
11
  /**
@@ -20,7 +22,9 @@ export interface GlosslintEslintOptions {
20
22
  kindOf?: KindOf;
21
23
  }
22
24
  /**
23
- * ESLint flat configs that run glosslint's rules: `...glosslint({ corpus, files })`. They set no
24
- * parser: your config supplies typescript-eslint, vue-eslint-parser or yaml-eslint-parser.
25
+ * ESLint flat configs that run glosslint's rules: `...glosslint()`. The corpus comes from `corpus`, else
26
+ * from the `glossary` file, else from `.agents/glossary.md`, read once when the config is built. They set
27
+ * no parser: your config supplies typescript-eslint, vue-eslint-parser, yaml-eslint-parser or
28
+ * jsonc-eslint-parser.
25
29
  */
26
- export default function glosslint(options: GlosslintEslintOptions): Linter.Config[];
30
+ export default function glosslint(options?: GlosslintEslintOptions): Linter.Config[];