From 166bb5b14b522e681dc7a911a9bba17854b91b68 Mon Sep 17 00:00:00 2001 From: Martin Date: Tue, 12 Sep 2017 13:58:39 +0200 Subject: [PATCH 1/3] Update README.md: add hint that addon needs to be registered --- addons/links/README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/addons/links/README.md b/addons/links/README.md index 9c34458a53cb..c1521af455f5 100644 --- a/addons/links/README.md +++ b/addons/links/README.md @@ -17,6 +17,14 @@ This addon works with Storybook for: You can use this addon without installing it. +First configure it as an addon by adding it to your addons.js file (located in the Storybook config directory). + +```js +import '@storybook/addon-knobs/register' +``` + +Then you can import `linkTo` in your stories and use like this: + ```js import { storiesOf } from '@storybook/react' import { linkTo } from '@storybook/addon-links' From 96534246f181783b907bf1ff2d2257849dbf1fd1 Mon Sep 17 00:00:00 2001 From: Martin Date: Tue, 12 Sep 2017 14:01:58 +0200 Subject: [PATCH 2/3] fix typo --- addons/links/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/links/README.md b/addons/links/README.md index c1521af455f5..8276949bd807 100644 --- a/addons/links/README.md +++ b/addons/links/README.md @@ -20,7 +20,7 @@ You can use this addon without installing it. First configure it as an addon by adding it to your addons.js file (located in the Storybook config directory). ```js -import '@storybook/addon-knobs/register' +import '@storybook/addon-links/register'; ``` Then you can import `linkTo` in your stories and use like this: From 242cb8a33907c811321baa50efc22a0b15b06a67 Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Tue, 12 Sep 2017 14:34:02 +0200 Subject: [PATCH 3/3] Update README.md --- addons/links/README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/addons/links/README.md b/addons/links/README.md index 8276949bd807..c4b8a4632181 100644 --- a/addons/links/README.md +++ b/addons/links/README.md @@ -15,7 +15,10 @@ This addon works with Storybook for: ## Getting Started -You can use this addon without installing it. +Install this addon by adding the `@storybook/addon-links` dependency: +```sh +yarn add @storybook/addon-links +``` First configure it as an addon by adding it to your addons.js file (located in the Storybook config directory).