From b80a4faba21ee7c4defe25162c6f77dbcaa3df6c Mon Sep 17 00:00:00 2001 From: Tom Crockett Date: Fri, 6 Jul 2018 17:31:42 -0700 Subject: [PATCH 1/3] Use react-dev-utils@next --- app/react-native/package.json | 2 +- .../src/server/config/webpack.config.js | 2 +- app/react/package.json | 2 +- lib/core/package.json | 2 +- lib/core/src/server/config/webpack.config.js | 4 +- .../src/server/config/webpack.config.prod.js | 2 +- yarn.lock | 134 +++++++----------- 7 files changed, 61 insertions(+), 87 deletions(-) diff --git a/app/react-native/package.json b/app/react-native/package.json index 0a75be5ae25b..815b2b3d74b4 100644 --- a/app/react-native/package.json +++ b/app/react-native/package.json @@ -29,7 +29,7 @@ "@storybook/channel-websocket": "4.0.0-alpha.12", "@storybook/core": "4.0.0-alpha.12", "@storybook/core-events": "4.0.0-alpha.12", - "@storybook/react-dev-utils": "^5.0.0", + "react-dev-utils": "next", "@storybook/ui": "4.0.0-alpha.12", "babel-loader": "^7.1.4", "babel-plugin-macros": "^2.2.2", diff --git a/app/react-native/src/server/config/webpack.config.js b/app/react-native/src/server/config/webpack.config.js index 7e9fc974150b..a9e3b90e8924 100644 --- a/app/react-native/src/server/config/webpack.config.js +++ b/app/react-native/src/server/config/webpack.config.js @@ -2,7 +2,7 @@ import path from 'path'; import webpack from 'webpack'; import { getEnvironment } from 'universal-dotenv'; import Dotenv from 'dotenv-webpack'; -import WatchMissingNodeModulesPlugin from '@storybook/react-dev-utils/WatchMissingNodeModulesPlugin'; +import WatchMissingNodeModulesPlugin from 'react-dev-utils/WatchMissingNodeModulesPlugin'; import CaseSensitivePathsPlugin from 'case-sensitive-paths-webpack-plugin'; import HtmlWebpackPlugin from 'html-webpack-plugin'; import { indexHtmlPath } from '@storybook/core/server'; diff --git a/app/react/package.json b/app/react/package.json index 0dc6664d074c..c1c072e38a03 100644 --- a/app/react/package.json +++ b/app/react/package.json @@ -23,7 +23,7 @@ }, "dependencies": { "@storybook/core": "4.0.0-alpha.12", - "@storybook/react-dev-utils": "^5.0.0", + "react-dev-utils": "next", "babel-plugin-react-docgen": "^2.0.0-rc.1", "babel-preset-react": "^6.24.1", "common-tags": "^1.8.0", diff --git a/lib/core/package.json b/lib/core/package.json index f6f3cc53485f..a3c6a3dde0b8 100644 --- a/lib/core/package.json +++ b/lib/core/package.json @@ -21,7 +21,7 @@ "@storybook/client-logger": "4.0.0-alpha.12", "@storybook/core-events": "4.0.0-alpha.12", "@storybook/node-logger": "4.0.0-alpha.12", - "@storybook/react-dev-utils": "^5.0.0", + "react-dev-utils": "next", "@storybook/ui": "4.0.0-alpha.12", "airbnb-js-shims": "^1.6.0", "autoprefixer": "^8.6.0", diff --git a/lib/core/src/server/config/webpack.config.js b/lib/core/src/server/config/webpack.config.js index b6a77978107c..9e81a1ab9e9e 100644 --- a/lib/core/src/server/config/webpack.config.js +++ b/lib/core/src/server/config/webpack.config.js @@ -2,8 +2,8 @@ import path from 'path'; import webpack from 'webpack'; import { getEnvironment } from 'universal-dotenv'; import Dotenv from 'dotenv-webpack'; -import InterpolateHtmlPlugin from '@storybook/react-dev-utils/InterpolateHtmlPlugin'; -import WatchMissingNodeModulesPlugin from '@storybook/react-dev-utils/WatchMissingNodeModulesPlugin'; +import InterpolateHtmlPlugin from 'react-dev-utils/InterpolateHtmlPlugin'; +import WatchMissingNodeModulesPlugin from 'react-dev-utils/WatchMissingNodeModulesPlugin'; import CaseSensitivePathsPlugin from 'case-sensitive-paths-webpack-plugin'; import HtmlWebpackPlugin from 'html-webpack-plugin'; diff --git a/lib/core/src/server/config/webpack.config.prod.js b/lib/core/src/server/config/webpack.config.prod.js index 052ea1de331b..082435548c55 100644 --- a/lib/core/src/server/config/webpack.config.prod.js +++ b/lib/core/src/server/config/webpack.config.prod.js @@ -1,7 +1,7 @@ import webpack from 'webpack'; import { getEnvironment } from 'universal-dotenv'; import Dotenv from 'dotenv-webpack'; -import InterpolateHtmlPlugin from '@storybook/react-dev-utils/InterpolateHtmlPlugin'; +import InterpolateHtmlPlugin from 'react-dev-utils/InterpolateHtmlPlugin'; import HtmlWebpackPlugin from 'html-webpack-plugin'; import { version } from '../../../package.json'; diff --git a/yarn.lock b/yarn.lock index 170f6ece48c7..326697e7dc3a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -153,18 +153,18 @@ dependencies: tslib "^1.9.0" -"@babel/code-frame@7.0.0-beta.42": - version "7.0.0-beta.42" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0-beta.42.tgz#a9c83233fa7cd06b39dc77adbb908616ff4f1962" - dependencies: - "@babel/highlight" "7.0.0-beta.42" - "@babel/code-frame@7.0.0-beta.44": version "7.0.0-beta.44" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0-beta.44.tgz#2a02643368de80916162be70865c97774f3adbd9" dependencies: "@babel/highlight" "7.0.0-beta.44" +"@babel/code-frame@7.0.0-beta.46": + version "7.0.0-beta.46" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0-beta.46.tgz#e0d002100805daab1461c0fcb32a07e304f3a4f4" + dependencies: + "@babel/highlight" "7.0.0-beta.46" + "@babel/code-frame@^7.0.0-beta.35": version "7.0.0-beta.37" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0-beta.37.tgz#2da1dd3b1b57bfdea777ddc378df7cd12fe40171" @@ -210,17 +210,17 @@ dependencies: "@babel/types" "7.0.0-beta.44" -"@babel/highlight@7.0.0-beta.42": - version "7.0.0-beta.42" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0-beta.42.tgz#a502a1c0d6f99b2b0e81d468a1b0c0e81e3f3623" +"@babel/highlight@7.0.0-beta.44": + version "7.0.0-beta.44" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0-beta.44.tgz#18c94ce543916a80553edcdcf681890b200747d5" dependencies: chalk "^2.0.0" esutils "^2.0.2" js-tokens "^3.0.0" -"@babel/highlight@7.0.0-beta.44": - version "7.0.0-beta.44" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0-beta.44.tgz#18c94ce543916a80553edcdcf681890b200747d5" +"@babel/highlight@7.0.0-beta.46": + version "7.0.0-beta.46" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0-beta.46.tgz#c553c51e65f572bdedd6eff66fc0bb563016645e" dependencies: chalk "^2.0.0" esutils "^2.0.2" @@ -374,33 +374,6 @@ babel-runtime "^6.11.6" immutable "^3.8.1" -"@storybook/react-dev-utils@^5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@storybook/react-dev-utils/-/react-dev-utils-5.0.0.tgz#d33a6baf480a980e135c21ade859632aca20fe78" - dependencies: - "@babel/code-frame" "7.0.0-beta.42" - address "1.0.3" - browserslist "3.2.0" - chalk "2.3.2" - cross-spawn "6.0.5" - detect-port-alt "1.1.5" - escape-string-regexp "1.0.5" - filesize "3.6.0" - find-pkg "1.0.0" - global-modules "1.0.0" - globby "8.0.1" - gzip-size "4.1.0" - inquirer "5.1.0" - is-root "1.0.0" - opn "5.3.0" - pkg-up "2.0.0" - react-error-overlay "^4.0.0" - recursive-readdir "2.2.2" - shell-quote "1.6.1" - sockjs-client "1.1.4" - strip-ansi "4.0.0" - text-table "0.2.0" - "@storybook/react-komposer@^2.0.1": version "2.0.3" resolved "https://registry.yarnpkg.com/@storybook/react-komposer/-/react-komposer-2.0.3.tgz#f9e12a9586b2ce95c24c137eabb8b71527ddb369" @@ -3400,12 +3373,12 @@ browserify@^9.0.3: vm-browserify "~0.0.1" xtend "^3.0.0" -browserslist@3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-3.2.0.tgz#3d4a99710c12101e4567c9aeedade49c958cb883" +browserslist@3.2.6, browserslist@^3.2.6: + version "3.2.6" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-3.2.6.tgz#138a44d04a9af64443679191d041f28ce5b965d5" dependencies: - caniuse-lite "^1.0.30000815" - electron-to-chromium "^1.3.39" + caniuse-lite "^1.0.30000830" + electron-to-chromium "^1.3.42" browserslist@^1.3.6, browserslist@^1.5.2, browserslist@^1.7.6: version "1.7.7" @@ -3421,13 +3394,6 @@ browserslist@^2.1.2, browserslist@^2.5.1: caniuse-lite "^1.0.30000789" electron-to-chromium "^1.3.30" -browserslist@^3.2.6: - version "3.2.6" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-3.2.6.tgz#138a44d04a9af64443679191d041f28ce5b965d5" - dependencies: - caniuse-lite "^1.0.30000830" - electron-to-chromium "^1.3.42" - browserslist@^3.2.8: version "3.2.8" resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-3.2.8.tgz#b0005361d6471f0f5952797a76fc985f1f978fc6" @@ -3699,10 +3665,6 @@ caniuse-lite@^1.0.30000748, caniuse-lite@^1.0.30000789: version "1.0.30000791" resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000791.tgz#8e35745efd483a3e23bb7d350990326d2319fc16" -caniuse-lite@^1.0.30000815: - version "1.0.30000820" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000820.tgz#6e36ee75187a2c83d26d6504a1af47cc580324d2" - caniuse-lite@^1.0.30000830: version "1.0.30000830" resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000830.tgz#cb96b8a2dd3cbfe04acea2af3c4e894249095328" @@ -3782,9 +3744,9 @@ chalk@1.1.3, chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" -chalk@2.3.2: - version "2.3.2" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.2.tgz#250dc96b07491bfd601e648d66ddf5f60c7a5c65" +chalk@2.4.1, chalk@^2.3.2, chalk@^2.4.1: + version "2.4.1" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e" dependencies: ansi-styles "^3.2.1" escape-string-regexp "^1.0.5" @@ -3806,14 +3768,6 @@ chalk@^2.3.1: escape-string-regexp "^1.0.5" supports-color "^5.2.0" -chalk@^2.3.2, chalk@^2.4.1: - version "2.4.1" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e" - dependencies: - ansi-styles "^3.2.1" - escape-string-regexp "^1.0.5" - supports-color "^5.3.0" - chalk@~0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/chalk/-/chalk-0.4.0.tgz#5199a3ddcd0c1efe23bc08c1b027b06176e0c64f" @@ -5480,13 +5434,6 @@ detect-node@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/detect-node/-/detect-node-2.0.3.tgz#a2033c09cc8e158d37748fbde7507832bd6ce127" -detect-port-alt@1.1.5: - version "1.1.5" - resolved "https://registry.yarnpkg.com/detect-port-alt/-/detect-port-alt-1.1.5.tgz#a1aa8fc805a4a5df9b905b7ddc7eed036bcce889" - dependencies: - address "^1.0.1" - debug "^2.6.0" - detect-port-alt@1.1.6: version "1.1.6" resolved "https://registry.yarnpkg.com/detect-port-alt/-/detect-port-alt-1.1.6.tgz#24707deabe932d4a3cf621302027c2b266568275" @@ -5771,10 +5718,6 @@ electron-to-chromium@^1.2.7, electron-to-chromium@^1.3.30: dependencies: electron-releases "^2.1.0" -electron-to-chromium@^1.3.39: - version "1.3.40" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.40.tgz#1fbd6d97befd72b8a6f921dc38d22413d2f6fddf" - electron-to-chromium@^1.3.42: version "1.3.44" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.44.tgz#ef6b150a60d523082388cadad88085ecd2fd4684" @@ -7023,9 +6966,9 @@ filesize@3.5.11: version "3.5.11" resolved "https://registry.yarnpkg.com/filesize/-/filesize-3.5.11.tgz#1919326749433bb3cf77368bd158caabcc19e9ee" -filesize@3.6.0: - version "3.6.0" - resolved "https://registry.yarnpkg.com/filesize/-/filesize-3.6.0.tgz#22d079615624bb6fd3c04026120628a41b3f4efa" +filesize@3.6.1: + version "3.6.1" + resolved "https://registry.yarnpkg.com/filesize/-/filesize-3.6.1.tgz#090bb3ee01b6f801a8a8be99d31710b3422bb317" fill-range@^2.1.0: version "2.2.3" @@ -14326,6 +14269,33 @@ react-dev-utils@^5.0.1: strip-ansi "3.0.1" text-table "0.2.0" +react-dev-utils@next: + version "6.0.0-next.3e165448" + resolved "https://registry.yarnpkg.com/react-dev-utils/-/react-dev-utils-6.0.0-next.3e165448.tgz#d573ed0ba692f6cee23166f99204e5761df0897c" + dependencies: + "@babel/code-frame" "7.0.0-beta.46" + address "1.0.3" + browserslist "3.2.6" + chalk "2.4.1" + cross-spawn "6.0.5" + detect-port-alt "1.1.6" + escape-string-regexp "1.0.5" + filesize "3.6.1" + find-pkg "1.0.0" + global-modules "1.0.0" + globby "8.0.1" + gzip-size "4.1.0" + inquirer "5.1.0" + is-root "1.0.0" + opn "5.3.0" + pkg-up "2.0.0" + react-error-overlay "5.0.0-next.3e165448" + recursive-readdir "2.2.2" + shell-quote "1.6.1" + sockjs-client "1.1.4" + strip-ansi "4.0.0" + text-table "0.2.0" + react-devtools-core@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/react-devtools-core/-/react-devtools-core-3.0.0.tgz#f683e19f0311108f97dbb5b29d948323a1bf7c03" @@ -14361,6 +14331,10 @@ react-emotion@^9.1.3: babel-plugin-emotion "^9.1.2" create-emotion-styled "^9.1.2" +react-error-overlay@5.0.0-next.3e165448: + version "5.0.0-next.3e165448" + resolved "https://registry.yarnpkg.com/react-error-overlay/-/react-error-overlay-5.0.0-next.3e165448.tgz#2cbd10780c1fa9c7e35d6e443773e18948b7ee49" + react-error-overlay@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/react-error-overlay/-/react-error-overlay-4.0.0.tgz#d198408a85b4070937a98667f500c832f86bd5d4" From 2f0cc50a75a2cc10ebf71b6e2b296fbde172b3c7 Mon Sep 17 00:00:00 2001 From: Tom Crockett Date: Wed, 18 Jul 2018 11:51:44 -0400 Subject: [PATCH 2/3] Set version range to ^6.0.0-next.3e165448 --- app/react-native/package.json | 2 +- app/react/package.json | 2 +- lib/core/package.json | 2 +- yarn.lock | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/react-native/package.json b/app/react-native/package.json index 815b2b3d74b4..9719e67865c4 100644 --- a/app/react-native/package.json +++ b/app/react-native/package.json @@ -29,7 +29,7 @@ "@storybook/channel-websocket": "4.0.0-alpha.12", "@storybook/core": "4.0.0-alpha.12", "@storybook/core-events": "4.0.0-alpha.12", - "react-dev-utils": "next", + "react-dev-utils": "^6.0.0-next.3e165448", "@storybook/ui": "4.0.0-alpha.12", "babel-loader": "^7.1.4", "babel-plugin-macros": "^2.2.2", diff --git a/app/react/package.json b/app/react/package.json index c1c072e38a03..197519892929 100644 --- a/app/react/package.json +++ b/app/react/package.json @@ -23,7 +23,7 @@ }, "dependencies": { "@storybook/core": "4.0.0-alpha.12", - "react-dev-utils": "next", + "react-dev-utils": "^6.0.0-next.3e165448", "babel-plugin-react-docgen": "^2.0.0-rc.1", "babel-preset-react": "^6.24.1", "common-tags": "^1.8.0", diff --git a/lib/core/package.json b/lib/core/package.json index a3c6a3dde0b8..4d31d60b8ae1 100644 --- a/lib/core/package.json +++ b/lib/core/package.json @@ -21,7 +21,7 @@ "@storybook/client-logger": "4.0.0-alpha.12", "@storybook/core-events": "4.0.0-alpha.12", "@storybook/node-logger": "4.0.0-alpha.12", - "react-dev-utils": "next", + "react-dev-utils": "^6.0.0-next.3e165448", "@storybook/ui": "4.0.0-alpha.12", "airbnb-js-shims": "^1.6.0", "autoprefixer": "^8.6.0", diff --git a/yarn.lock b/yarn.lock index 326697e7dc3a..fb35947f55d1 100644 --- a/yarn.lock +++ b/yarn.lock @@ -14269,7 +14269,7 @@ react-dev-utils@^5.0.1: strip-ansi "3.0.1" text-table "0.2.0" -react-dev-utils@next: +react-dev-utils@^6.0.0-next.3e165448: version "6.0.0-next.3e165448" resolved "https://registry.yarnpkg.com/react-dev-utils/-/react-dev-utils-6.0.0-next.3e165448.tgz#d573ed0ba692f6cee23166f99204e5761df0897c" dependencies: From 211ee175ea58d9422156978111b02faa625f796e Mon Sep 17 00:00:00 2001 From: Tom Crockett Date: Wed, 18 Jul 2018 12:02:23 -0400 Subject: [PATCH 3/3] Remove @storybook/ prefix --- app/react-native/package.json | 2 +- app/react/package.json | 2 +- lib/core/package.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/react-native/package.json b/app/react-native/package.json index 183f30c859dc..16f61b93ea63 100644 --- a/app/react-native/package.json +++ b/app/react-native/package.json @@ -29,7 +29,6 @@ "@storybook/channel-websocket": "4.0.0-alpha.14", "@storybook/core": "4.0.0-alpha.14", "@storybook/core-events": "4.0.0-alpha.14", - "@storybook/react-dev-utils": "^6.0.0-next.3e165448", "@storybook/ui": "4.0.0-alpha.14", "babel-loader": "^7.1.4", "babel-plugin-macros": "^2.2.2", @@ -55,6 +54,7 @@ "json5": "^1.0.1", "prop-types": "^15.6.1", "raw-loader": "^0.5.1", + "react-dev-utils": "^6.0.0-next.3e165448", "react-native-compat": "^1.0.0", "react-native-iphone-x-helper": "^1.0.3", "shelljs": "^0.8.2", diff --git a/app/react/package.json b/app/react/package.json index 0d62df8e8b36..ecf5030f99c8 100644 --- a/app/react/package.json +++ b/app/react/package.json @@ -23,7 +23,6 @@ }, "dependencies": { "@storybook/core": "4.0.0-alpha.14", - "@storybook/react-dev-utils": "^6.0.0-next.3e165448", "babel-plugin-react-docgen": "^2.0.0-rc.1", "babel-preset-react": "^6.24.1", "common-tags": "^1.8.0", @@ -31,6 +30,7 @@ "global": "^4.3.2", "lodash.flattendeep": "^4.4.0", "prop-types": "^15.6.1", + "react-dev-utils": "^6.0.0-next.3e165448", "react-emotion": "^9.1.3" }, "peerDependencies": { diff --git a/lib/core/package.json b/lib/core/package.json index cd8030af831e..d334ffe36899 100644 --- a/lib/core/package.json +++ b/lib/core/package.json @@ -21,7 +21,6 @@ "@storybook/client-logger": "4.0.0-alpha.14", "@storybook/core-events": "4.0.0-alpha.14", "@storybook/node-logger": "4.0.0-alpha.14", - "@storybook/react-dev-utils": "^6.0.0-next.3e165448", "@storybook/ui": "4.0.0-alpha.14", "airbnb-js-shims": "^1.6.0", "autoprefixer": "^8.6.0", @@ -52,6 +51,7 @@ "prop-types": "^15.6.1", "qs": "^6.5.2", "raw-loader": "^0.5.1", + "react-dev-utils": "^6.0.0-next.3e165448", "react-emotion": "^9.1.3", "redux": "^4.0.0", "serve-favicon": "^2.5.0",