-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Amplify is not a proper es6 module #2199
Comments
I tried doing: |
The documentation makes little to no mention of this issue and really should be updated to reflect the limitations of the package only being available in CommonJS format until all of the tasks in #2309 are complete. This would avoid a lot of frustration and wasted time for developers who are keen to work with the package. I saw mention of configuring Webpack for bundling modules in one page of the documentation but other pages - including the README.md of this repo - are very misleading in that they read as though the developer should be able to directly import amplify-js in the browser. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This issue has been automatically closed because of inactivity. Please open a new issue if are still encountering problems. |
This issue has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs. Looking for a help forum? We recommend joining the Amplify Community Discord server |
Describe the bug
Unable to use the package at all without Webpack loaders. I get
The requested module '../../node_modules/@aws-amplify/core/lib/index.js' does not provide an export named 'default'
To Reproduce
Steps to reproduce the behavior:
npm install --save aws-amplify
import Amplify from 'aws-amplify' in
my-app.js`Expected behavior
Amplify should be an es6 module, not just fake that it is by putting
Object.defineProperty(exports, "__esModule", { value: true });
at the top of the packageDesktop (please complete the following information):
Additional context
This ticket says that the package needs to have an export, which is not the case for aws-amplify
The text was updated successfully, but these errors were encountered: