harper.js 1.0.0 → 1.2.0

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/harper.d.ts CHANGED
@@ -194,7 +194,7 @@ declare class Linter_2 {
194
194
  * Helper method to remove non-English text from a plain English document.
195
195
  */
196
196
  isolate_english(text: string): string;
197
- organized_lints(text: string, language: Language): OrganizedGroup[];
197
+ organized_lints(text: string, language: Language, all_headings: boolean): OrganizedGroup[];
198
198
  summarize_stats(start_time?: bigint | null, end_time?: bigint | null): any;
199
199
  /**
200
200
  * Apply a suggestion from a given lint.
@@ -245,7 +245,7 @@ declare class Linter_2 {
245
245
  /**
246
246
  * Perform the configured linting on the provided text.
247
247
  */
248
- lint(text: string, language: Language): Lint[];
248
+ lint(text: string, language: Language, all_headings: boolean): Lint[];
249
249
  }
250
250
 
251
251
  /** The properties and information needed to construct a Linter. */
@@ -260,6 +260,8 @@ export declare interface LinterInit {
260
260
  export declare interface LintOptions {
261
261
  /** The markup language that is being passed. Defaults to `markdown`. */
262
262
  language?: 'plaintext' | 'markdown';
263
+ /** Force the entirety of the document to be composed of headings. An undefined value is assumed to be false.*/
264
+ forceAllHeadings?: boolean;
263
265
  }
264
266
 
265
267
  /** A Linter that runs in the current JavaScript context (meaning it is allowed to block the event loop).