Learn how to create a mutation for signing in.
- [Instructor] In our last video,…we created our CreateUser mutation.…And in this video,…we're going to make our SignInUser mutation.…These are the two key mutations we'll need…for our auth process.…I'm going to go to my file tree and in Mutations,…I'm going to make a New File.…I'll call this SignInUser.js.…One thing you'll find when you're making relay mutations…is that for the most part,…their syntax is the same.…That means that in this file,…I can just copy and paste everything…and then I'll change it to suit my needs.…
Here in SignInUser, I'll paste everything…and I'll scroll up to the top…and begin to look at what I can change.…All right, here on line one,…I want import Relay from 'react' so that'll stay.…Here on line three,…instead of saying that this is a CreateUser mutation,…I want to say this is SignInUser…and then I can begin to change getVariables.…I happen to know from reading in docs on graph.cool…that we don't even need to provide an email when we sign in.…Actually, we don't need to say authProvider either.…
- Installing local dependencies
- Generating a starter project
- Deploying to Heroku
- Planning your development process
- Using styled-components
- Styling for mobile
- Setting up models on Graphcool
- Creating Relay mutations
- Adding Relay to your authentication flow
- Protecting routes with authentication
Skill Level Intermediate
Building a Web Interface with React.jswith Ray Villalobos1h 21m Intermediate
2. Deployment Environments
3. App Functionality
4. Implementing Libraries
5. Creating Components
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.