Skip to content

Instantly share code, notes, and snippets.

@annjawn
Last active December 5, 2018 19:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save annjawn/4cbdabe26af8800e3edae8e2c9f81f06 to your computer and use it in GitHub Desktop.
Save annjawn/4cbdabe26af8800e3edae8e2c9f81f06 to your computer and use it in GitHub Desktop.
Modular import of amplify core
import Amplify from '@aws-amplify/core';
export function configureAmplify() {
Amplify.configure(
{
Auth: {
identityPoolId: process.env.REACT_APP_identityPoolId,
region: process.env.REACT_APP_region,
userPoolId: process.env.REACT_APP_userPoolId,
userPoolWebClientId: process.env.REACT_APP_userPoolWebClientId,
},
Storage: {
bucket: process.env.REACT_APP_Bucket_name,
region: process.env.REACT_APP_region,
identityPoolId: process.env.REACT_APP_identityPoolId
}
}
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment