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

Bug: Export namespace should be first transformed by @babel/plugin-transform-export-namespace-from. #181

Closed
WilliamYWY opened this issue Dec 15, 2023 · 2 comments · Fixed by #202
Labels
bug Something isn't working

Comments

@WilliamYWY
Copy link
Contributor

Describe the bug

After updating xmtp to the latest version using npm I got this error

node_modules/@xmtp/proto/ts/dist/esm/index.js:
Export namespace should be first transformed by @babel/plugin-transform-export-namespace-from.

> 1 | export * as messageApi from "./message_api/v1/message_api.pb";
    |        ^^^^^^^^^^^^^^^
  2 | export * as fetcher from "./fetch.pb";
  3 | export * as authn from "./message_api/v1/authn.pb";
  4 | export * as message from "./message_contents/message.pb";

Expected behavior

If someone encounters the same issue, I resolve it by adding the below plugins in babel.config.js

{
plugins: ["@babel/plugin-transform-export-namespace-from"]
}

Hope this help

Steps to reproduce the bug

No response

@WilliamYWY WilliamYWY added the bug Something isn't working label Dec 15, 2023
@kele-leanes
Copy link
Contributor

hi @WilliamYWY can you please provide more information about the issue? how your environment is configured? Have you installed the package in expo or bare RN project?

@alexrisch
Copy link
Contributor

Hello!
I just came across this issue, it happens when transitioning from a bare react native project and needing to install.

I will make sure something along the following is added to the ReadMe:

Install the required babel plugin:
yarn add @babel/plugin-proposal-export-namespace-from -D

Add '@babel/plugin-proposal-export-namespace-from' to your list of plugins in the babel.config.js file

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.

3 participants