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

Error: "Could neither find styled-components secret internals" when import #301

Closed
Duncan00 opened this issue Jan 24, 2020 · 5 comments
Closed

Comments

@Duncan00
Copy link

In a jest test:

import 'jest-styled-components';

When run test, will get error:

Could neither find styled-components secret internals

Versions:

"styled-components": "4.2.0"
"jest-styled-components": "7.0.0"

Similar issue here: https://stackoverflow.com/questions/59860271/could-neither-find-styled-components-secret-internals

Thanks!

@valentinbourqui
Copy link

There is already a ticket #297

@kachkaev
Copy link
Member

Duplicate of #297

@kachkaev kachkaev marked this as a duplicate of #297 Jan 24, 2020
@PravallikaVinod
Copy link

@Duncan00 Is above issue solved?

@santanapaulo
Copy link

As mentioned on this comment #315 (comment), if you guys update your styled-component lib to some version higher than >5.0.0, it should work.

I was having the same issue, and it worked well to me.

@vanduc1102
Copy link

vanduc1102 commented Aug 5, 2021

There is a warning when i have "styled-components": "4.4.1", and run yarn add yarn add jest-styled-components
warning " > jest-styled-components@7.0.5" has incorrect peer dependency "styled-components@>= 5".

Change to yarn add jest-styled-components@6.3.4 solve the issue.

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

6 participants