Linting your ionic app before running has huge advantages. It will analyse code for potential errors and save you tremendous amount of time.
"Linting is the process of running a program that will analyse code for potential errors." - see What is "Linting"?
Your ionic app comes with a package.json file. Go to the root of you app in a Command Line/Terminal and install the following packages:
npm install jshint --save-dev npm install jshint-stylish --save-dev npm install gulp-jshint --save-dev