This repository has been archived by the owner on Jul 12, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 144
Update linting, testing, @types/*
dependencies
#8475
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
chihsuan
changed the title
Update all linting, testing,
Update linting, testing, Mar 16, 2022
@types/*
dependencies@types/*
dependencies
chihsuan
force-pushed
the
dev/8425-update-lint-test-tools
branch
2 times, most recently
from
March 16, 2022 09:13
43a6c0a
to
f7064a2
Compare
chihsuan
force-pushed
the
dev/8425-update-lint-test-tools
branch
2 times, most recently
from
March 17, 2022 08:54
699dfcf
to
2528aed
Compare
chihsuan
force-pushed
the
dev/8425-update-lint-test-tools
branch
from
March 17, 2022 09:23
201b934
to
829ec68
Compare
adrianduffell
approved these changes
Mar 18, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This tested well and LGTM, thank you @chihsuan! 🚀
…int-plugin-testing-library to 5
Fix stylelint.config.js
Remove parameters
Add a comment for @storybook/addon-knobs
chihsuan
force-pushed
the
dev/8425-update-lint-test-tools
branch
from
March 18, 2022 11:15
67df47e
to
18a31a4
Compare
ObliviousHarmony
pushed a commit
to woocommerce/woocommerce
that referenced
this pull request
Mar 18, 2022
…erce-admin#8475) * Update husky from 4 to 7 * Update @types/jest from 26 to 27 * Update lint-staged from 10 to 12 * Update babel-jest from 26 to 27 * Update @typescript-eslint/eslint-plugin from 4 to 5 * Update @typescript-eslint/parser from 4 to 5 * Update chalk from 4 to 5 * Update concurrently from 5 to 7 * Update stylelint from 9 to 14 and stylelint-config-wordpress from 13 to 17 * Update @wordpress/prettier-config from 0.4 to 1.1 * Update eslint from 7 to 8, @wordpress/eslint-plugin from 8 to 10, eslint-plugin-testing-library to 5 * Fix lint errors after updating eslint-plugin-testing-library * Fix style lint * Rename .stylelintrc.json -> stylelint.config.js & add todo comment Fix stylelint.config.js * Remove @wordpress/e2e-test-utils * Add changelogs for eslint-plugin * Update storybook/preview.js since addDecorator has been deprecated Remove parameters * Import directly from @storybook/addon-docs * Migrate some stories to use @storybook/addon-controls Add a comment for @storybook/addon-knobs * Update changelogs * Update preview.js to fix lint warning * Update pnpm-lock.yaml * Fix eslint layout errors (woocommerce/woocommerce-admin#8484)
7 tasks
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #8425 and woocommerce/woocommerce#32153
This PR updates the linting, testing, and @types/* dependencies to the latest version with major/breaking changes.
Most of breaking changes:
Changes made due to dependencies upgrade:
@mixin break-small
block..scss
for @import commands to fixat-import-partial-extension
..stylelintrc.json
tostylelint.config.js
to add comments.husky
config with husky-4-to-7 CLI.husky 4 to 7
v7.0.0
.husky/
directory structure..husky/.gitignore
is now unnecessary and can be removed.@types/jest 26 to 27
We have already upgraded to jest v27.
babel-jest 26 to 27
lint-staged 10 to 12
Node version and ESM modules breaking changes only.
v12
v11
@typescript-eslint/eslint-plugin, @typescript-eslint/parser 4 to 5
These packages are required by
@wordpress/eslint-plugin
and we've also updated the@wordpress/eslint-plugin
to the latest version in this PR.CHANGELOG.md
ban-types
no longer reports object by defaultchalk 4 to 5
We don't use the properties that changed from v4 to v5.
v5.0.0
This package is now pure ESM. Please read this.
overline
style and removekeyword
,hsl
,hsv
,hwb
andansi
color spaces chalk/chalk#433) chalk/chalk@4cf2e40Concurrently 5 to 7
We only use Concurrently CLI so concurrently() API changes don't affect us.
v7.0.0
v6.0.0
@wordpress/prettier-config to v1
CHANGELOG.md
Update stylelint 9 to 14
We use this with
@wordpress/stylelint-config
and it has supported stylelint 14 in the latest version.CHANGELOG.md
stylelint-config-wordpress 13 to @wordpress/stylelint-config 20
CHANGELOG.md
Breaking Change
eslint 7 to 8
@wordpress/eslint-plugin@v10
is compatible with eslint v8 and I don't see anything breaking our@woocommerce/eslint-plugin
.Migrating to v8.0.0
@wordpress/eslint-plugin 8 to 10
jsdoc/check-line-alignment
eslint warnings #8484 to fixjsdoc/check-line-alignment
eslint warningsCHANGELOG.md
Breaking Changes:
eslint-plugin-testing-library 3 to 5
->
'plugin:testing-library/react'`Remove @wordpress/e2e-test-utils
We don't use this directly and it's included in
@woocommerce/e2e*
dependencies.Update storybook config
We've already upgraded storybook to v6 but it seems that our config didn't update.
addParameters
andaddDecorator
. Instead,use export const parameters = {};
andexport const decorators = [];
withA11y
<List/>
story to import directly from '@storybook/addon-docs'Migrate @storybook/addon-knobs to @storybook/addon-controls
@storybook/addon-knobs
has been deprecated, in favor of@storybook/addon-controls
.I've converted most of the stories to use
@storybook/addon-controls
. However, I found@storybook/addon-controls
have trouble with<Timeline />
. It seems that we cannot have jsx elements in props.Therefore, I still have
@storybook/addon-knob
in our dependencies.puppeteer & @wordpress/scripts
I'll create a follow-up issue for them because
@wordpress/scripts
requires the changes in #8476. Andpuppeteer
need to be compatible with@wordpress/scripts
.Test Instructions
pnpm install
pnpm run lint
&pnpm run test
&pnpm run build
still worklint-staged
,husky
workno changelog