Getting Started With Ionic 5

ionic start

Every great app needs a name!

Please enter the full name of your app. You can change this at any time. To bypass this prompt next time, supply name,
the first argument to ionic start.

? Project name: diyawanna

Pick a framework!

Please select the JavaScript framework to use for your new app. To bypass this prompt next time, supply a value for the
--type option.

? Framework: (Use arrow keys)
> Angular | https://angular.io
  React   | https://reactjs.org

Let's pick the perfect starter template!

Starter templates are ready-to-go Ionic apps that come packed with everything you need to build your app. To bypass this
prompt next time, supply template, the second argument to ionic start.

? Starter template: (Use arrow keys)
> tabs         | A starting project with a simple tabbed interface
  sidemenu     | A starting project with a side menu with navigation in the content area
  blank        | A blank starter project
  my-first-app | An example application that builds a camera with gallery
  conference   | A kitchen-sink application that shows off all Ionic has to offer

√ Preparing directory .\diyawanna - done!
√ Downloading and extracting tabs starter - done!

Installing dependencies may take several minutes.

  ─────────────────────────────────────────────────────────

         Ionic Advisory, tailored solutions and expert services by Ionic

                             Go to market faster
                    Real-time troubleshooting and guidance
        Custom training, best practices, code and architecture reviews
      Customized strategies for every phase of the development lifecycle

               Learn more: https://ion.link/advisory

  ─────────────────────────────────────────────────────────

npm.cmd i
npm WARN deprecated

? Would you like to share anonymous usage data with the Angular Team at Google under
Google’s Privacy Policy at https://policies.google.com/privacy? For more details and
how to change this setting, see http://angular.io/analytics. (y/N)

https://ionicframework.com/docs/components




cd diyawanna
ionic serve

[INFO] Development server running!

       Local: http://localhost:8100

       Use Ctrl+C to quit this process

[INFO] Browser window opened to http://localhost:8100!

[ng] i 「wdm」: Compiled successfully.


ionic cordova platform add android

[ERROR] An error occurred while running subprocess cordova.

        cordova.cmd platform add android exited with exit code 1.

        Re-running this command with the --verbose flag may provide more information.

cordova -v
npm install -g cordova

+ cordova@9.0.0
added 237 packages from 169 contributors, removed 218 packages and updated 106 packages in 111.85s

ionic cordova platform rm android
 cordova.cmd platform remove android

ionic cordova platform add android
cordova.cmd platform add android
[WARN] cordova-res was not found on your PATH. Please install it globally:
[WARN] Cannot generate resources without cordova-res installed.

npm i -g cordova-res
ionic cordova resources android --force
 cordova-res.cmd android
[cordova-res] Generated 18 resources for android
[cordova-res] Wrote to config.xml

ionic cordova run android
[ERROR] native-run was not found on your PATH. Please install it globally:

npm i -g native-run
+ native-run@1.0.0
added 30 packages from 33 contributors in 13.308s

ionic cordova run android
BUILD SUCCESSFUL in 33s
1 actionable task: 1 executed
Subproject Path: CordovaLib
Subproject Path: app
Downloading https://services.gradle.org/distributions/gradle-4.10.3-all.zip


* What went wrong:
A problem occurred configuring project ':app'.
> Failed to install the following Android SDK packages as some licences have not been accepted.
     platforms;android-28 Android SDK Platform 28
  To build this project, accept the SDK license agreements and install the missing components using the Android Studio SDK Manager.
  Alternatively, to transfer the license agreements from one workstation to another, see http://d.android.com/r/studio-ui/export-licenses.html

  Using Android SDK: E:\Setups\sdk

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 6m 26s
[ERROR] An error occurred while running subprocess cordova.


ionic info
Ionic:

   Ionic CLI                     : 5.4.16 (C:\Users\S A H A N\AppData\Roaming\npm\node_modules\ionic)
   Ionic Framework               : @ionic/angular 5.0.7
   @angular-devkit/build-angular : 0.803.26
   @angular-devkit/schematics    : 8.3.26
   @angular/cli                  : 8.3.26
   @ionic/angular-toolkit        : 2.2.0

Cordova:

   Cordova CLI       : 9.0.0 (cordova-lib@9.0.1)
   Cordova Platforms : android 8.1.0
   Cordova Plugins   : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 4.1.3, (and 5 other plugins)

Utility:

   cordova-res : 0.11.0
   native-run  : 1.0.0

System:

   Android SDK Tools : 26.1.1 (E:\Setups\sdk)
   NodeJS            : v12.16.1 (C:\Program Files\nodejs\node.exe)
   npm               : 6.13.4
   OS                : Windows 10


ionic cordova run android
BUILD SUCCESSFUL in 1m 47s
42 actionable tasks: 42 executed
Built the following apk(s):
        E:\@Projects\Ionic\NEW\diyawanna\platforms\android\app\build\outputs\apk\debug\app-debug.apk
> native-run.cmd android --app platforms\android\app\build\outputs\apk\debug\app-debug.apk
[native-run] No hardware devices found, attempting emulator...
[native-run] Selected emulator emulator-5554
[native-run] Installing platforms\android\app\build\outputs\apk\debug\app-debug.apk...
[native-run] Starting application activity io.ionic.starter/io.ionic.starter.MainActivity...
[native-run] Run Successful

ionic cordova run android --device
BUILD SUCCESSFUL in 9s
42 actionable tasks: 42 up-to-date
Built the following apk(s):
        E:\@Projects\Ionic\NEW\diyawanna\platforms\android\app\build\outputs\apk\debug\app-debug.apk
> native-run.cmd android --app platforms\android\app\build\outputs\apk\debug\app-debug.apk --device
[native-run] ERR_NO_DEVICE: No hardware devices found. Not attempting emulator because --device was specified.
[ERROR] An error occurred while running subprocess native-run.




Comments

Popular posts from this blog

Ionic3 Project Types

How To Install Different Ionic versions in One Environment.