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

Not all displayNames are removed #1

Closed
svitovyda opened this issue May 9, 2023 · 2 comments · Fixed by #2
Closed

Not all displayNames are removed #1

svitovyda opened this issue May 9, 2023 · 2 comments · Fixed by #2
Assignees
Labels
bug Something isn't working

Comments

@svitovyda
Copy link

Describe the bug
Please see my little sandbox project
If you will run yarn build:prod without transform-react-remove-display-name, you will find 25 "displayName" in output/main.js. If you will enable it, there will still be 7 "displayName", probably because those are the names of the components, wrapped into the HOC

To Reproduce
Steps to reproduce the behavior:

  1. download https://github.com/svitovyda/udemy-react-swapi
  2. build it, as described in README
  3. run yarn build:prod
  4. Open output/main.js
  5. See 7 occurrences of setting the displayName

Expected behavior
0 displayName in the resulting production code

@svitovyda svitovyda added the bug Something isn't working label May 9, 2023
@felixmosh
Copy link
Owner

Hi @svitovyda, I'm glad that this lib is helpfull for you.
This lib was created for learning purpose & to solve a specific use-case, which it does.

I'm a bit busy lately, so it may take sometime.
If you have some time, will happy to review a PR that solves your use-cases.

@felixmosh
Copy link
Owner

HOC detection is added in v1.1.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants