Skip to content
This repository has been archived by the owner on Aug 18, 2020. It is now read-only.

v31.0.0

Compare
Choose a tag to compare
@cartogram cartogram released this 23 Oct 05:20
· 80 commits to master since this release

Typescript Parser Changes

  • Breaking Change Updated from eslint-plugin-typescript to @typescript-eslint/eslint-plugin. If you have any rules defined under the typescript namespace, you will need to change those to use the new @typescript-eslint namespace.

For example:

"rules": {
  "typescript/restrict-plus-operands": "error"
}

Will become:

"rules": {
  "@typescript-eslint/restrict-plus-operands": "error"
}
  • Note If using the plugin:shopify/typescript-type-checking augmented config, you must specify a path to your tsconfig.json file in the "project" property of "parserOptions"

React Config Changes

  • Breaking Change The plugin:shopify/react is no longer a core config and must augment one of the plugin:shopify/typescript or plugin:shopify/esnext configs. See examples below

Example config for react without typescript projects:

{
  "extends": [
    "plugin:shopify/esnext",
    "plugin:shopify/react",
    "// ...other plugins"
  ]
}

Example config for react with typescript projects:

{
  "extends": [
    "plugin:shopify/typescript",
    "plugin:shopify/react",
    "// ...other plugins"
  ]
}

New Rules

  • jest/no-standalone-expect Prevents expect statements outside of a test or it block (368)
  • jest/no-expect-resolves Avoid using expect().resolves (370)

Dependencies

  • As of this version, you will need to be upgrade to eslint@^6.0.0 within your project.