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

Profiler import is added multiple times #1

Open
jlopez2-rbi opened this issue Aug 16, 2022 · 6 comments
Open

Profiler import is added multiple times #1

jlopez2-rbi opened this issue Aug 16, 2022 · 6 comments

Comments

@jlopez2-rbi
Copy link

I followed the setup instructions and got the following error at runtime:

SyntaxError: /lib/index.js: Identifier 'Profiler' has already been declared. (3:9)
1 | import { onRenderCallBack$ } from "babel-plugin-wrap-profiler/lib/profiler-utils";
2 | import { Profiler } from "react";
3 | import { Profiler } from "react";

index.js

import { onRenderCallBack$ } from "babel-plugin-wrap-profiler/lib/profiler-utils";
import { Profiler } from "react";
import { Profiler } from "react";

Other components show Profiler being imported multiple times in the same import statement:

import { onRenderCallBack$ } from "babel-plugin-wrap-profiler/lib/profiler-utils";
import React, { Profiler, Profiler, Profiler, Profiler, Profiler, Profiler, Profiler, Profiler, Profiler, Profiler, Profiler } from 'react';

Project Details:

  • Expo managed React Native Project: v5.4.3
  • node: v14.19.0
  • @babel/core: 7.12.9
@chakrihacker
Copy link
Owner

Hey @jlopez2-rbi Will look into this in weekend

@chakrihacker
Copy link
Owner

Can you share some code snippet or repo that will help me reproduce it quickly?

@jlopez2-rbi
Copy link
Author

Unfortunately the repo is private, have you seen this bug in an empty boilerplate RN project?

@chakrihacker
Copy link
Owner

Unfortunately the repo is private, have you seen this bug in an empty boilerplate RN project?

Nope

Can you share your react and react native version?

@jlopez2-rbi
Copy link
Author

"react": "17.0.2",
"react-native": "0.68.2",

@chakrihacker
Copy link
Owner

Hey, I just tried this on my side and was not able to reproduce it. If you can provide a repo with a reproduction of the issue I can help further

Repository owner deleted a comment from H4wk-eye Feb 21, 2024
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