-
-
Notifications
You must be signed in to change notification settings - Fork 9.2k
Description
Bug report
What is the current behavior?
The production build of our website crashes due to an issue with the 'aws-amplify' dependency. In the console we see the following error:
Uncaught TypeError: Cannot read property 'configure' of undefined
This is in reference to the following code from the source file, app.tsx, which contains the lines (among others):
import Amplify from "aws-amplify";
Amplify.configure({ Auth: {} })
So it appears as though the 'aws-amplify' package is not being correctly included in the output bundle. Note that this page works fine when built using webpack version 4.43.0.
If the current behavior is a bug, please provide the steps to reproduce.
You can reproduce this bug by cloning the repository here and following the instructions in the README.
What is the expected behavior?
The page should load without error and display the text "Hello World!" in the top left corner.
Other relevant information:
webpack version: 4.44.0
Node.js version: 14.4.0
Operating System: Windows 10
Additional tools: