Skip to content

Commit

Permalink
Improve doc about GA
Browse files Browse the repository at this point in the history
  • Loading branch information
Vadorequest committed Jan 12, 2021
1 parent 5c0e75c commit b79e94e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
13 changes: 11 additions & 2 deletions .storybook/main.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,20 @@
module.exports = {
'stories': [
stories: [
'../src/**/*.stories.mdx',
'../src/**/*.stories.@(js|jsx|ts|tsx)',
],
'addons': [
addons: [
'@storybook/addon-links',
'@storybook/addon-essentials',

/**
* We use Google Analytics for tracking analytics usage.
*
* It's much easier to setup than Amplitude, because there is an official dedicated plugin for this.
* See ".storybook/manager.js" for Google Analytics configuration.
*
* @see https://github.com/storybookjs/storybook/tree/master/addons/google-analytics
*/
'@storybook/addon-google-analytics',
],
};
6 changes: 1 addition & 5 deletions .storybook/preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,7 @@ import dataset from './mock/sb-dataset';
* - We don't want to track analytics using Amplitude.
* - All analytics is disabled when running a component through Storybook preview.
*
* About Google analytics:
* - We use Google Analytics for tracking analytics usage.
* - It's much easier to setup than Amplitude, because there is an official dedicated plugin for this.
* - See ".storybook/manager.js" for GA configuration.
* - See https://github.com/storybookjs/storybook/tree/master/addons/google-analytics
* About Google analytics, see ".storybook/main.js" documentation.
*/
const customer = find(dataset, { __typename: 'Customer' });
const customerTheme = initCustomerTheme(customer);
Expand Down

0 comments on commit b79e94e

Please sign in to comment.