Skip to content

Commit

Permalink
chore: Fix styleguide build
Browse files Browse the repository at this point in the history
  • Loading branch information
jessieweiyi committed Nov 8, 2022
1 parent c2b32fa commit c3453ea
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 19 deletions.
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,8 @@
"glob-parent": "^5.1.2",
"trim": "^0.0.3",
"trim-newlines": "^3.0.1",
"terser": "^5.15.1"
"terser": "^5.15.1",
"react-docgen-typescript": "2.2.2"
},
"workspaces": {
"packages": [
Expand Down
4 changes: 2 additions & 2 deletions packages/legacy/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
"prettier": "^2.7.1",
"react": "^17.0.2",
"react-docgen-typescript-loader": "^3.6.0",
"react-docgen-typescript-webpack-plugin": "^1.1.0",
"react-docgen-typescript-plugin": "^1.0.2",
"react-dom": "^17.0.2",
"react-map-gl": "^6.1.19",
"react-pivottable": "^0.11.0",
Expand All @@ -112,7 +112,7 @@
"style-loader": "^3.3.1",
"ts-jest": "^29.0.3",
"ts-loader": "^9.4.1",
"typescript": "4.2.4",
"typescript": "^4.8.4",
"url-loader": "^4.1.1",
"webpack": "^5.69.1"
},
Expand Down
4 changes: 4 additions & 0 deletions packages/legacy/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ const SRC_PATH = path.join(__dirname, './src');
const DOC_COMPONENTS_SRC_PATH = path.join(__dirname, './docs/components');
const STYLE_GUIDE_PATH = path.join(__dirname, './styleguide');
const CopyPlugin = require('copy-webpack-plugin');
const ReactDocgenTypescriptPlugin = require('react-docgen-typescript-plugin').default;

module.exports = {
resolve: {
Expand All @@ -35,6 +36,9 @@ module.exports = {
},
],
}),
new ReactDocgenTypescriptPlugin({
include: [path.join(SRC_PATH, '**', '*.tsx')],
}),
],

optimization: {
Expand Down
2 changes: 1 addition & 1 deletion scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ STYLEGUIDE_FOLDER_LEGACY=./packages/legacy/styleguide.out/
STYLEGUIDE_FOLDER_LEGACY_EXAMPLE=${STYLEGUIDE_FOLDER_LEGACY}examples/
EXAMPLES_FOLDER=./packages/examples/

yarn install
yarn install --frozen-lockfile
yarn test:ci
yarn styleguide:build
yarn storybook:build
Expand Down
44 changes: 29 additions & 15 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4342,9 +4342,9 @@
integrity sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw==

"@types/react-dom@<18.0.0", "@types/react-dom@^17", "@types/react-dom@^17.0.9":
version "17.0.17"
resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-17.0.17.tgz#2e3743277a793a96a99f1bf87614598289da68a1"
integrity sha512-VjnqEmqGnasQKV0CWLevqMTXBYG9GbwuE6x3VetERLh0cq2LTptFE73MrQi2S7GkKXCf2GgwItB/melLnxfnsg==
version "17.0.18"
resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-17.0.18.tgz#8f7af38f5d9b42f79162eea7492e5a1caff70dc2"
integrity sha512-rLVtIfbwyur2iFKykP2w0pl/1unw26b5td16d5xMgp7/yjTHomkyxPYChFoCr/FtEX1lN9wY6lFj1qvKdS5kDw==
dependencies:
"@types/react" "^17"

Expand Down Expand Up @@ -15118,6 +15118,20 @@ react-docgen-typescript-loader@^3.6.0:
loader-utils "^1.2.3"
react-docgen-typescript "^1.15.0"

react-docgen-typescript-plugin@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/react-docgen-typescript-plugin/-/react-docgen-typescript-plugin-1.0.2.tgz#79ad8eadb1b63e43575a1c75429dfdabbfd0d35d"
integrity sha512-/8OKrPRDTAGDnOkumGvDWixfrNPrRWhEMGLZnJr1NiJtRwdvNRGqGA2J/SeSvWerawqSPxNyXK+EfERCir6mMw==
dependencies:
debug "^4.1.1"
endent "^2.0.1"
find-cache-dir "^3.3.1"
flat-cache "^3.0.4"
micromatch "^4.0.2"
react-docgen-typescript "^2.2.2"
tslib "^2.0.0"
webpack-sources "^2.2.0"

react-docgen-typescript-webpack-plugin@^1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/react-docgen-typescript-webpack-plugin/-/react-docgen-typescript-webpack-plugin-1.1.0.tgz#4bfb8c3312fce487083924842cf03f66177ab9df"
Expand All @@ -15126,12 +15140,7 @@ react-docgen-typescript-webpack-plugin@^1.1.0:
ajv "^6.1.1"
react-docgen-typescript "^1.2.3"

react-docgen-typescript@^1.15.0, react-docgen-typescript@^1.2.3:
version "1.22.0"
resolved "https://registry.yarnpkg.com/react-docgen-typescript/-/react-docgen-typescript-1.22.0.tgz#00232c8e8e47f4437cac133b879b3e9437284bee"
integrity sha512-MPLbF8vzRwAG3GcjdL+OHQlhgtWsLTXs+7uJiHfEeT3Ur7IsZaNYqRTLQ9sj2nB6M6jylcPCeCmH7qbszJmecg==

react-docgen-typescript@^2.1.1:
react-docgen-typescript@2.2.2, react-docgen-typescript@^1.15.0, react-docgen-typescript@^1.2.3, react-docgen-typescript@^2.1.1, react-docgen-typescript@^2.2.2:
version "2.2.2"
resolved "https://registry.yarnpkg.com/react-docgen-typescript/-/react-docgen-typescript-2.2.2.tgz#4611055e569edc071204aadb20e1c93e1ab1659c"
integrity sha512-tvg2ZtOpOi6QDwsb3GZhOjDkkX0h8Z2gipvTg6OVMUyoYoURhEiRNePT8NZItTVCDh39JJHnLdfCOkzoLbFnTg==
Expand Down Expand Up @@ -17791,7 +17800,12 @@ trim-newlines@^1.0.0, trim-newlines@^3.0.0, trim-newlines@^3.0.1:
resolved "https://registry.yarnpkg.com/trim-newlines/-/trim-newlines-3.0.1.tgz#260a5d962d8b752425b32f3a7db0dcacd176c144"
integrity sha512-c1PTsA3tYrIsLGkJkzHF+w9F2EyxfXGo4UyJc4pFL++FMjnq0HJS69T3M7d//gKrFKwy429bouPescbjecU+Zw==

trim-trailing-lines@^1.0.0, trim@0.0.1, trim@^0.0.3:
trim-trailing-lines@^1.0.0:
version "1.1.4"
resolved "https://registry.yarnpkg.com/trim-trailing-lines/-/trim-trailing-lines-1.1.4.tgz#bd4abbec7cc880462f10b2c8b5ce1d8d1ec7c2c0"
integrity sha512-rjUWSqnfTNrjbB9NQWfPMH/xRK1deHeGsHoVfpxJ++XeYXE0d6B1En37AHfw3jtfTU7dzMzZL2jjpe8Qb5gLIQ==

trim@0.0.1, trim@^0.0.3:
version "0.0.3"
resolved "https://registry.yarnpkg.com/trim/-/trim-0.0.3.tgz#05243a47a3a4113e6b49367880a9cca59697a20b"
integrity sha512-h82ywcYhHK7veeelXrCScdH7HkWfbIT1D/CgYO+nmDarz3SGNssVBMws6jU16Ga60AJCRAvPV6w6RLuNerQqjg==
Expand Down Expand Up @@ -17971,10 +17985,10 @@ typedarray@^0.0.6:
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
integrity sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA==

typescript@4.2.4:
version "4.2.4"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.2.4.tgz#8610b59747de028fda898a8aef0e103f156d0961"
integrity sha512-V+evlYHZnQkaz8TRBuxTA92yZBPotr5H+WhQ7bD3hZUndx5tGOa1fuCgeSjxAzM1RiN5IzvadIXTVefuuwZCRg==
typescript@^4.8.4:
version "4.8.4"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.8.4.tgz#c464abca159669597be5f96b8943500b238e60e6"
integrity sha512-QCh+85mCy+h0IGff8r5XWzOVSbBO+KfeYrMQh7NJ58QujwcE22u+NUSmUxqF+un70P9GXKxa2HCNiTTMJknyjQ==

uglify-js@^3.1.4:
version "3.17.3"
Expand Down Expand Up @@ -18739,7 +18753,7 @@ webpack-sources@^1.4.0, webpack-sources@^1.4.1, webpack-sources@^1.4.3:
source-list-map "^2.0.0"
source-map "~0.6.1"

webpack-sources@^2.0.1:
webpack-sources@^2.0.1, webpack-sources@^2.2.0:
version "2.3.1"
resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-2.3.1.tgz#570de0af163949fe272233c2cefe1b56f74511fd"
integrity sha512-y9EI9AO42JjEcrTJFOYmVywVZdKVUfOvDUPsJea5GIr1JOEGFVqwlY2K098fFoIjOkDzHn2AjRvM8dsBZu+gCA==
Expand Down

0 comments on commit c3453ea

Please sign in to comment.