Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

textlint 9.0.0 Release Notes #304

Closed
azu opened this issue Sep 23, 2017 · 4 comments
Closed

textlint 9.0.0 Release Notes #304

azu opened this issue Sep 23, 2017 · 4 comments
Labels
Type: Maintenance Repository Maintenance

Comments

@azu
Copy link
Member

azu commented Sep 23, 2017

textlint 9.0.0 ChangeLog

♻️ Refactor

textlint-kernel: Convert JavaScript to TypeScript #248 #301

Convert @textlint/kernel from JavaScript to Typescript.

If you instersting in TypeScript support, please see #248 .

Currently, Type definition is unstable. It means that break change in minor version.

🆕 Feature

Plugins can be initialized with plugin options #296

Allow to specify following options.

{
  "plugins": {
     "text": { "custom": "value" }
  }
}

For mode details, See document of plugin.

textlint-tester: support "index" expected param #324

Allow to write following index based testing.

const TextLintTester = require("textlint-tester");
const tester = new TextLintTester();
tester.run("rule", rule, {
    invalid: [
        // index
        {
            text: "- [ ] string",
            errors: [
                {
                    message: "Found TODO: '- [ ] string'",
                    index: 2
                }
            ]
        }
    ]
});

🐛 Bug Fixes

textlint: don't use error.code when catch error #323

Fix to use correct exit code. Thanks to @buzztaiki

🔥 BREAKING CHANGE

These breaking change is for plugin/rule author.

Remove context.config #294 #295

You can use context.getConfigBaseDir() instead of context.config.

  • getConfigBaseDir() return config base directory path that is the place of .textlintrc
    • e.g.) /path/to/dir/.textlintrc
    • getConfigBaseDir() return "/path/to/dir/".

Related rules changes:

Drop "rules" and "rulesConfig" from plugin #291 #313

You can use preset feature instead of plugin.
The textlint plugin should focus on processor.

Disallow to use 3rd argument of context.report function #316

It prevent wrong usage of report function:

NG:

report(node,
  new RuleError(`using "please" in a set of instructions is overdoing the politeness.`), {
    index,
    fix: fixer.replaceTextRange(range, result.replace)
  }
)

OK:

report(node,
  new RuleError(`using "please" in a set of instructions is overdoing the politeness.`, {
    index,
    fix: fixer.replaceTextRange(range, result.replace)
  });
)
@azu azu added the Type: Maintenance Repository Maintenance label Sep 23, 2017
@azu
Copy link
Member Author

azu commented Oct 24, 2017

You can try

npm install textlint@8.3.0-alpha.6a53d00c

@azu
Copy link
Member Author

azu commented Oct 24, 2017

We will release textlint@9 in this week.

@azu azu changed the title textlint@9 changes textlint 9.0.0 Release Notes Oct 27, 2017
@azu
Copy link
Member Author

azu commented Oct 27, 2017

We have released (final) beta :shipit:

You can try it.

npm install textlint@9.0.0-beta.0

@azu
Copy link
Member Author

azu commented Oct 28, 2017

@azu azu closed this as completed Oct 28, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Maintenance Repository Maintenance
Projects
None yet
Development

No branches or pull requests

1 participant