In this tutorial we are going to explain how to add Log in, Log out, and Sign up functionality to your ionic app using the Ionic Platform services.
Follow the step-by-step instructions available here: https://ionicthemes.com/tutorials/about/add-ionic-platform-authentication-to-your-ionic-app
You can find the Ionic official installation documentation here.
- Make sure you have an up-to-date version of Node.js installed on your system. If you don't have Node.js installed, you can install it from here.
- Open a terminal (Mac) or a command interpreter (
cmd
, Windows), and install Cordova and Ionic:npm install -g cordova
npm install -g ionic
- On a Mac, you may have to use
sudo
depending on your system configuration:sudo npm install -g cordova ionic
- If you already have Cordova and Ionic installed on your computer, make sure you update to the latest version:
npm update -g cordova
npm update -g ionic
- Or
sudo npm update -g cordova ionic
Follow these links if you want more information:
First we need to link this new Ionic project with our reference repo on github. Clone this repo so we can start working on the app:
git clone https://github.com/ionicthemes/ionic-platform-authentication-for-your-ionic-app.git
cd ionic-auth
After this, we need to set up some stuff before starting working on the Ionic project. To do so, run these commands:
npm install
bower install
As we are going to use Ionic Platform services, we need to install and init the platform services with this command:ionic add ionic-platform-web-client
ionic io init
NOTE: The last step is critical, if we install the ionic-platform-web-client but don't init, then we may find some bugs when serving the app.
Finally, to see the current state of the project, run:
ionic serve