Skip to content

Commit 8a18a8e

Browse files
Merge pull request #20 from hipstersmoothie/deps
update deps
2 parents 20119aa + f8dd5fb commit 8a18a8e

6 files changed

Lines changed: 5980 additions & 19 deletions

File tree

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
node_modules
2-
yarn.lock
32
dist
43
.env
File renamed without changes.

package.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"debug": "^4.1.1",
2828
"endent": "^2.0.1",
2929
"micromatch": "^4.0.2",
30-
"react-docgen-typescript": "^1.20.1",
30+
"react-docgen-typescript": "^1.20.5",
3131
"tslib": "^2.0.0"
3232
},
3333
"devDependencies": {
@@ -37,18 +37,18 @@
3737
"@types/node": "^14.0.12",
3838
"@types/react": "^17.0.0",
3939
"@types/webpack": "^4.41.17",
40-
"@typescript-eslint/eslint-plugin": "2.31.0",
41-
"@typescript-eslint/parser": "2.31.0",
40+
"@typescript-eslint/eslint-plugin": "^4.9.0",
41+
"@typescript-eslint/parser": "^4.9.0",
4242
"auto": "^10.2.3",
4343
"auto-config-hipstersmoothie": "^4.0.0",
44-
"eslint": "7.0.0",
45-
"eslint-config-airbnb-base": "14.1.0",
44+
"eslint": "^7.14.0",
45+
"eslint-config-airbnb-base": "^14.2.1",
4646
"eslint-config-prettier": "6.11.0",
4747
"eslint-config-xo": "0.29.1",
48-
"eslint-plugin-import": "2.20.2",
48+
"eslint-plugin-import": "^2.22.1",
4949
"eslint-plugin-jest": "^24.1.3",
5050
"eslint-plugin-jsdoc": "25.2.0",
51-
"eslint-plugin-jsx-a11y": "6.2.3",
51+
"eslint-plugin-jsx-a11y": "^6.4.1",
5252
"eslint-plugin-prettier": "3.1.3",
5353
"jest": "^26.6.3",
5454
"prettier": "^2.0.5",

src/generateDocgenCodeBlock.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,15 @@ import path from "path";
22
import ts from "typescript";
33
import { ComponentDoc, PropItem } from "react-docgen-typescript";
44

5+
export interface GeneratorOptions {
6+
filename: string;
7+
source: string;
8+
componentDocs: ComponentDoc[];
9+
docgenCollectionName: string | null;
10+
setDisplayName: boolean;
11+
typePropName: string;
12+
}
13+
514
/**
615
* Inserts a ts-ignore comment above the supplied statement.
716
*
@@ -312,15 +321,6 @@ function setComponentDocGen(
312321
);
313322
}
314323

315-
export interface GeneratorOptions {
316-
filename: string;
317-
source: string;
318-
componentDocs: ComponentDoc[];
319-
docgenCollectionName: string | null;
320-
setDisplayName: boolean;
321-
typePropName: string;
322-
}
323-
324324
export function generateDocgenCodeBlock(options: GeneratorOptions): string {
325325
const sourceFile = ts.createSourceFile(
326326
options.filename,

src/plugin.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ export default class DocgenPlugin {
146146
this.options = options;
147147
}
148148

149-
apply(compiler: webpack.Compiler) {
149+
apply(compiler: webpack.Compiler): void {
150150
const {
151151
tsconfigPath = "./tsconfig.json",
152152
docgenCollectionName = "STORYBOOK_REACT_CLASSES",
@@ -168,7 +168,10 @@ export default class DocgenPlugin {
168168
};
169169

170170
if (userCompilerOptions) {
171-
compilerOptions = { ...compilerOptions, ...userCompilerOptions };
171+
compilerOptions = {
172+
...compilerOptions,
173+
...userCompilerOptions,
174+
};
172175
} else {
173176
const { options } = getTSConfigFile(tsconfigPath);
174177
compilerOptions = { ...compilerOptions, ...options };

0 commit comments

Comments
 (0)