Even though facebook has its documentation about how to do their social login, I still cannot finish without searching for other resources. There are some parts missing in its documentation.
The missing code in AppDelegate.swift
Make our own button in our LoginViewController.swift
The StoryboardID
is used for LogoutViewController.swift to return back
Pressed Cancelled while logging in:
Successfully logged in. You can also print out user’s facebookID using FBSDKAccessToken.current().userID
Logout Button
Things aren’t that hard. It’s just that some pieces are missing, making such simple task a bit difficult.