Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Constantly getting error with styled component and typescript #35

Closed
pantharshit00 opened this issue Jun 14, 2018 · 3 comments
Closed

Comments

@pantharshit00
Copy link

Module build failed (from ./node_modules/happypack/loader.js):
TypeError: Cannot read property 'kind' of undefined
    at getLiteralValueFromPropertyAssignment (/root/ui-lib/node_modules/react-docgen-typescript/lib/parser.js:359:25)
    at /root/ui-lib/node_modules/react-docgen-typescript/lib/parser.js:336:28
    at Array.reduce (<anonymous>)
    at getPropMap (/root/ui-lib/node_modules/react-docgen-typescript/lib/parser.js:332:30)
    at /root/ui-lib/node_modules/react-docgen-typescript/lib/parser.js:304:37
    at Array.forEach (<anonymous>)
    at Parser.extractDefaultPropsFromComponent (/root/ui-lib/node_modules/react-docgen-typescript/lib/parser.js:299:37)
    at Parser.getComponentInfo (/root/ui-lib/node_modules/react-docgen-typescript/lib/parser.js:118:37)
    at /root/ui-lib/node_modules/react-docgen-typescript/lib/parser.js:73:57
    at Array.map (<anonymous>)
    at /root/ui-lib/node_modules/react-docgen-typescript/lib/parser.js:73:22
    at Array.reduce (<anonymous>)
    at Object.parse (/root/ui-lib/node_modules/react-docgen-typescript/lib/parser.js:66:18)
    at Object.processResource (/root/ui-lib/node_modules/react-docgen-typescript-loader/dist/loader.js:69:32)
    at Object.loader (/root/ui-lib/node_modules/react-docgen-typescript-loader/dist/loader.js:15:41)
    at applySyncOrAsync (/root/ui-lib/node_modules/happypack/lib/applyLoaders.js:350:21)

 @ ./components/Button/Button.mdx 3:0-38 33:99-105
 @ ./.docz/app/imports.js
 @ ./.docz/app/index.jsx
 @ multi ./node_modules/babel-polyfill/lib/index.js ./.docz/app/index.jsx

Hey I am getting this error and I cant help it. Please help I am using typescript and styled-components

Repo: https://github.com/javascript-af/ui-lib

The stuff is in docz branch.

OS: Windows 10 (using bash on windows(ubuntu))
Node:- v8.11.2

@pantharshit00
Copy link
Author

Is it related to react docgen?

@pantharshit00
Copy link
Author

pantharshit00 commented Jun 15, 2018

Thanks @pedronauck for the PR on my repo. It started docz fine but there is a issue with PropsTable which I showed in this issue.

harshit-test-org/ui-lib#1 (comment)

Should I need to open an new issue for that?

@pedronauck
Copy link
Member

Fix on v0.2.5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants