Skip to content

Commit

Permalink
Merge pull request #20246 from storybookjs/shilman/20149-restore-docs…
Browse files Browse the repository at this point in the history
…-blocks-entry

Addon-docs: Restore deprecated blocks entry point
  • Loading branch information
shilman authored Dec 14, 2022
2 parents b999502 + 7228361 commit 970ebea
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
6 changes: 6 additions & 0 deletions code/addons/docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,11 @@
"import": "./dist/preset.mjs",
"types": "./dist/preset.d.ts"
},
"./blocks": {
"require": "./dist/blocks.js",
"import": "./dist/blocks.mjs",
"types": "./dist/blocks.d.ts"
},
"./dist/preview": {
"require": "./dist/preview.js",
"import": "./dist/preview.mjs",
Expand Down Expand Up @@ -132,6 +137,7 @@
"./src/index.ts",
"./src/preset.ts",
"./src/preview.ts",
"./src/blocks.ts",
"./src/shims/mdx-react-shim.ts"
]
},
Expand Down
7 changes: 7 additions & 0 deletions code/addons/docs/src/blocks.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { deprecate } from '@storybook/client-logger';

deprecate(
"Import from '@storybook/addon-docs/blocks' is deprecated. Please import from '@storybook/blocks' instead."
);

export * from '@storybook/blocks';

0 comments on commit 970ebea

Please sign in to comment.