diff --git a/blog/atom.xml b/blog/atom.xml index d6267e43..bad634c8 100644 --- a/blog/atom.xml +++ b/blog/atom.xml @@ -13,7 +13,7 @@ https://textlint.github.io/blog/2024/02/03/textlint-14.html 2024-02-03T06:00:00.000Z - We are pleased to announce the release of textlint v14.0.0. This release includes a number of new features and improvements.

Summary

textlint v14 requires Node.js v18.14.0;.

Node.js 16 is already EOL, so we drop support for Node.js 16. If you use old...

]]>
+ We are pleased to announce the release of textlint v14.0.0. This release includes a number of new features and improvements.

Summary

textlint v14 requires Node.js v18.14.0;.

Node.js 16 is already EOL, so we drop support for Node.js 16. If you use old...

]]>
azu http://github.com/azu @@ -35,7 +35,7 @@ https://textlint.github.io/blog/2021/05/24/textlint-12.html 2021-05-24T06:00:00.000Z - We just publish textlint v12.0.0, which is a major release upgrade of textlint.

This release adds some new features and fixes several bugs found in the previous release. This release also has some breaking changes.

Summary

For textlint user

textlint ...

]]>
+ We just publish textlint v12.0.0, which is a major release upgrade of textlint.

This release adds some new features and fixes several bugs found in the previous release. This release also has some breaking changes.

Summary

For textlint user

textlint ...

]]>
azu http://github.com/azu @@ -46,7 +46,7 @@ https://textlint.github.io/blog/2018/07/22/textlint-11.html 2018-07-22T06:00:00.000Z - We just pushed textlint v11.0.0, which is a major release upgrade of textlint.

This release adds some new features and fixes several bugs found in the previous release. This release also has some breaking changes.

Highlights

⭐️ Features

@textlint/text...

]]>
+ We just pushed textlint v11.0.0, which is a major release upgrade of textlint.

This release adds some new features and fixes several bugs found in the previous release. This release also has some breaking changes.

Highlights

⭐️ Features

@textlint/text...

]]>
azu http://github.com/azu diff --git a/blog/feed.xml b/blog/feed.xml index 05218283..85e9c735 100644 --- a/blog/feed.xml +++ b/blog/feed.xml @@ -18,7 +18,7 @@ https://textlint.github.io/blog/2024/02/03/textlint-14.html https://textlint.github.io/blog/2024/02/03/textlint-14.html Sat, 03 Feb 2024 06:00:00 GMT - We are pleased to announce the release of textlint v14.0.0. This release includes a number of new features and improvements.

Summary

textlint v14 requires Node.js v18.14.0;.

Node.js 16 is already EOL, so we drop support for Node.js 16. If you use old...

]]>
+ We are pleased to announce the release of textlint v14.0.0. This release includes a number of new features and improvements.

Summary

textlint v14 requires Node.js v18.14.0;.

Node.js 16 is already EOL, so we drop support for Node.js 16. If you use old...

]]>
<![CDATA[textlint v13.0.0]]> @@ -32,14 +32,14 @@ https://textlint.github.io/blog/2021/05/24/textlint-12.html https://textlint.github.io/blog/2021/05/24/textlint-12.html Mon, 24 May 2021 06:00:00 GMT - We just publish textlint v12.0.0, which is a major release upgrade of textlint.

This release adds some new features and fixes several bugs found in the previous release. This release also has some breaking changes.

Summary

For textlint user

textlint ...

]]>
+ We just publish textlint v12.0.0, which is a major release upgrade of textlint.

This release adds some new features and fixes several bugs found in the previous release. This release also has some breaking changes.

Summary

For textlint user

textlint ...

]]>
<![CDATA[textlint 11 released]]> https://textlint.github.io/blog/2018/07/22/textlint-11.html https://textlint.github.io/blog/2018/07/22/textlint-11.html Sun, 22 Jul 2018 06:00:00 GMT - We just pushed textlint v11.0.0, which is a major release upgrade of textlint.

This release adds some new features and fixes several bugs found in the previous release. This release also has some breaking changes.

Highlights

⭐️ Features

@textlint/text...

]]>
+ We just pushed textlint v11.0.0, which is a major release upgrade of textlint.

This release adds some new features and fixes several bugs found in the previous release. This release also has some breaking changes.

Highlights

⭐️ Features

@textlint/text...

]]>
<![CDATA[New website]]> diff --git a/docs/use-as-modules.html b/docs/use-as-modules.html index d203ef50..f496e088 100644 --- a/docs/use-as-modules.html +++ b/docs/use-as-modules.html @@ -81,11 +81,13 @@

  • fixFiles and fixText does not modify files
  • +
  • scanFilePath(filePath): Promise<ScanFilePathResult> check the the file path is lintable or not
  • loadTextlintrc: load .textlintrc config file and return a descriptor object
  • loadLinerFormatter and loadFixerFormatter: load formatter
  • -

    Lint files and output to console.

    +

    Examples

    +

    Lint files and output to console

    import { createLinter, loadTextlintrc, loadLinterFormatter } from "textlint";
     // descriptor is a structure object for linter
     // It includes rules, plugins, and options
    @@ -99,7 +101,7 @@ 

    const output = formatter.format(results); console.log(output);

    -

    Fix text and get the fixed text.

    +

    Fix text and get the fixed text

    import { createLinter, loadTextlintrc } from "textlint";
     // descriptor is a structure object for linter
     // It includes rules, plugins, and options
    @@ -110,7 +112,7 @@ 

    const result = await linter.fixText("TODO: fix me", "DUMMY.md"); console.log(result.output); // fixed result

    -

    Add custom rules and plugins.

    +

    Add custom rules and plugins

    import { createLinter, loadTextlintrc } from "textlint";
     import { TextlintKernelDescriptor } from "@textlint/kernel";
     import { moduleInterop } from "@textlint/module-interop";
    @@ -135,16 +137,29 @@ 

    // if same ruleId or pluginId, customDescriptor is used. descriptor: customDescriptor.concat(textlintrcDescriptor) }); -const result = await linter.lintText("TODO: fix me"); +const result = await linter.lintText("TODO: fix me", "README.md"); console.log(result);

    -

    Get lintable file extensions. -textlintrcDescriptor.availableExtensions provide list of supported file extensions.

    +

    Get lintable file extensions

    +

    textlintrcDescriptor.availableExtensions provide list of supported file extensions.

    import { createLinter, loadTextlintrc } from "textlint";
     const textlintrcDescriptor = await loadTextlintrc();
     const availableExtensions = textlintrcDescriptor.availableExtensions;
     console.log(availableExtensions); // => [".md", ".txt"]
     
    +

    Want to know the file path is lintable or not

    +
    import { createLinter, loadTextlintrc } from "textlint";
    +const textlintrcDescriptor = await loadTextlintrc();
    +const linter = createLinter({
    +    descriptor: textlintrcDescriptor
    +});
    +const result = await linter.scanFilePath("README.md");
    +// result.status is "ok" or "ignored" or "error"
    +if (result.status === "ok") {
    +    const lintResult = await linter.lintText("README content", "README.md");
    +    console.log(lintResult);
    +}
    +

    Deprecated APIs

    [Deprecated] Engine

    textlint has two engines TextLintEngine and TextFixEngine.

    @@ -206,7 +221,7 @@

  • spellcheck-tech-word-textlint-rule/test.js at master · azu/spellcheck-tech-word-textlint-rule
  • -