This repository has been archived by the owner on Jan 20, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AP-714 Use storybook docs
- Loading branch information
Showing
25 changed files
with
3,778 additions
and
2,511 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,16 @@ | ||
import { configure } from "@storybook/react"; | ||
|
||
function importAll(r) { | ||
r.keys().forEach(r); | ||
} | ||
|
||
function loadStories() { | ||
importAll( | ||
require.context("../src", true, /\.(?:stories|story)\.(jsx?|tsx?)$/) | ||
); | ||
import "../reset.css"; | ||
import "../font.css"; | ||
|
||
importAll( | ||
require.context("../stories", true, /\.(?:stories|story)\.(jsx?|tsx?)$/) | ||
); | ||
|
||
require("../reset.css"); | ||
require("../font.css"); | ||
} | ||
import { configure } from "@storybook/react"; | ||
|
||
configure(loadStories, module); | ||
configure( | ||
[ | ||
require.context("../src", true, /\.(?:stories|story)\.(jsx?|tsx?|mdx)$/), | ||
require.context( | ||
"../stories", | ||
true, | ||
/\.(?:stories|story)\.(jsx?|tsx?|mdx)$/ | ||
), | ||
], | ||
module | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/* eslint-disable @typescript-eslint/no-var-requires */ | ||
const path = require("path"); | ||
|
||
module.exports = [ | ||
{ | ||
name: "@storybook/preset-typescript", | ||
options: { | ||
tsLoaderOptions: { | ||
transpileOnly: true, | ||
}, | ||
tsDocgenLoaderOptions: { | ||
// Specify this manually or the loader won't find the config. See | ||
// https://github.com/strothj/react-docgen-typescript-loader/issues/10 | ||
tsconfigPath: path.resolve(__dirname, "../tsconfig.json"), | ||
}, | ||
}, | ||
}, | ||
"@storybook/addon-docs/react/preset", | ||
]; |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.