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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to Storybook 7 + fix vulnerabilities #19

Merged
merged 6 commits into from Dec 21, 2022

Conversation

vbartonicek
Copy link
Contributor

@vbartonicek vbartonicek commented Dec 21, 2022

Before:
Screen Shot 2022-12-20 at 9 23 22 PM

What I did:

  1. npm audit fix to fix some of the vulnerabilities
  2. npx storybook@next upgrade --prerelease to automatically upgrade Storybook to 7.0.0-beta.13
  3. Rewrote custom story sort within .storybook/preview.jsx as described in https://github.com/storybookjs/storybook/blob/next/MIGRATION.md#v7-style-story-sort
  4. npm install --save-dev webpack to tackle following issue - Storybook build fails with "Cannot find module 'webpack/lib/util/makeSerializable.js" after upgrading storybook packages to 6.3.0聽storybookjs/storybook#15336
  5. npm audit fix - this run couldn't fix glob-parent <5.1.2 vulnerability
  6. Deleted node-modules & package-lock.json and ran npm install to get rid of glob-parent <5.1.2 vulnerability

馃摎 Resources:
Storybook 7.0 beta - https://storybook.js.org/blog/7-0-beta/
Storybook 7 migration guide - https://chromatic-ui.notion.site/Storybook-7-migration-guide-dbf41fa347304eb2a5e9c69b34503937

After:
Screen Shot 2022-12-20 at 9 19 18 PM

Screen Shot 2022-12-20 at 9 18 44 PM

@linear
Copy link

linear bot commented Dec 21, 2022

PSL-1380 Update NPM dependencies and fix vulnerabilities

I just cloned the repo and running npm install reported 22 vulnerabilities.

Business Outcome:

As an Engineer I want to make sure our dependencies are up-to-date so that our repo's security&stability is increased.

Definition of done:

  • Update NPM dependencies to latest version
  • Fix all vulnerabilities

Additional Notes:

Some packages are deprecated and need a major update, e.g.

  • fsevents@1 => 2
  • chokidar@2.1.8 => 3

Screenshot

Screen Shot 2022-11-15 at 9.37.05 AM.png

@vbartonicek
Copy link
Contributor Author

I'm bit confused by GitHub check failing on error TS2322: Type 'ConstructorIO' is not assignable to type 'CioClient' which seems to be unrelated to my changes 馃

@vbartonicek vbartonicek requested review from a team December 21, 2022 05:30
Copy link
Contributor

@deomsj deomsj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

馃敟 馃敟 馃敟 Feels so good to have a clean terminal after npm ci

FYI: pushed a few commits to get our type definitions in this repo to play nice with updated type definitions in cio-client-js repo :)

@deomsj deomsj added the release:minor for version and release github action label Dec 21, 2022
@deomsj deomsj merged commit 6966f7d into main Dec 21, 2022
@deomsj deomsj deleted the psl-1380-update-npm-dependencies-and-fix branch December 21, 2022 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release:minor for version and release github action
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants