adding latest
This commit is contained in:
30
tutorial.md
Normal file
30
tutorial.md
Normal file
@@ -0,0 +1,30 @@
|
||||
Install amplify globally
|
||||
|
||||
`yarn global add @aws-amplify/cli`
|
||||
|
||||
Create new amplify app in project
|
||||
|
||||
`amplify init`
|
||||
|
||||
Amplify commands after init
|
||||
|
||||
`amplify status` - will show you what you've added already and if it's locally configured or deployed
|
||||
`amplify add <category>` - will allow you to add features like user login or a backend API
|
||||
`amplify push` - will build all your local backend resources and provision it in the cloud
|
||||
`amplify console` - to open the Amplify Console and view your project status
|
||||
`amplify publish` - will build all your local backend and frontend resources (if you have hosting category added) and provision it in the cloud
|
||||
|
||||
`amplify add api` - to create a backend API and then
|
||||
`amplify publish` - to deploy everything
|
||||
|
||||
Install aws amplify dependencies into project
|
||||
`yarn add aws-amplify aws-amplify-vue`
|
||||
|
||||
Add the Amplify instance to Vue instance in `main.js`
|
||||
Create a new js file in `./src/utils/auth.js` - write the aws amplify code in here.
|
||||
|
||||
You need to write a function for each auth flow. Signup, GetUser etc.
|
||||
|
||||
Remember to use
|
||||
`export {getUser, signUp, confirmSignUp, resendSignUp, signIn, signOut}`
|
||||
at the end so it can be imported later.
|
||||
Reference in New Issue
Block a user