Ionic 3 : npm install admob-free UNMEET PEER DEPENDENCIES.
I cannot import the AdmobFree Library to the Ionic 3 project. It show error when i do npm install.
When I type :
npm install --save #ionic-native/admob-free
it show :
+-- #ionic-native/admob-free#4.5.2
`-- UNMET PEER DEPENDENCY #ionic-native/core#4.4.0
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#^1.0.0 (node_modules\chokidar\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#1.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN #ionic-native/admob#3.14.0 requires a peer of #ionic-native/core#^3.6.0 but none was installed.
for more detal, this is my package.json :
{
"name": "AcehTourismMap",
"version": "0.0.1",
"author": "Ionic Framework",
"homepage": "http://ionicframework.com/",
"private": true,
"scripts": {
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"lint": "ionic-app-scripts lint",
"ionic:build": "ionic-app-scripts build",
"ionic:serve": "ionic-app-scripts serve"
},
"dependencies": {
"#angular/common": "5.0.3",
"#angular/compiler": "5.0.3",
"#angular/compiler-cli": "5.0.3",
"#angular/core": "5.0.3",
"#angular/forms": "5.0.3",
"#angular/http": "5.0.3",
"#angular/platform-browser": "5.0.3",
"#angular/platform-browser-dynamic": "5.0.3",
"#ionic-native/admob": "^3.14.0",
"#ionic-native/admob-free": "^4.5.2",
"#ionic-native/core": "^4.4.0",
"#ionic-native/launch-navigator": "^4.5.2",
"#ionic-native/splash-screen": "4.4.0",
"#ionic-native/status-bar": "^4.4.0",
"#ionic/storage": "2.1.3",
"cordova-admob-sdk": "^0.13.1",
"cordova-android": "~7.0.0",
"cordova-plugin-actionsheet": "^2.3.3",
"cordova-plugin-admob-free": "^0.13.0",
"cordova-plugin-device": "^1.1.4",
"cordova-plugin-dialogs": "^2.0.1",
"cordova-plugin-ionic-webview": "^1.1.16",
"cordova-plugin-splashscreen": "^4.0.3",
"cordova-plugin-statusbar": "^2.4.1",
"cordova-plugin-whitelist": "^1.3.1",
"cordova-promise-polyfill": "0.0.2",
"ionic-angular": "3.9.2",
"ionic-plugin-keyboard": "^2.2.1",
"ionicons": "3.0.0",
"rxjs": "5.5.2",
"sw-toolbox": "3.6.0",
"uk.co.workingedge.phonegap.plugin.launchnavigator": "^4.1.3",
"zone.js": "0.8.18"
},
"devDependencies": {
"#ionic/app-scripts": "3.1.6",
"typescript": "2.4.2"
},
"description": "An Ionic project",
"cordova": {
"plugins": {
"ionic-plugin-keyboard": {},
"cordova-plugin-whitelist": {},
"cordova-plugin-device": {},
"cordova-plugin-splashscreen": {},
"cordova-plugin-ionic-webview": {},
"cordova-plugin-statusbar": {},
"uk.co.workingedge.phonegap.plugin.launchnavigator": {},
"cordova-plugin-admob-free": {}
},
"platforms": [
"android"
]
}
}
How to fix this? The plugin/library not downloaded, and I cannot import the AdmobFree library
import { AdMobFree } from '#ionic-native/admob-free';
Thank you for the answer, I really appreciate, thank you......
Related
I'm trying to install a cordova plugin in my ionic app. But Every time and every plugin I try to install throws an error:
Cannot find module 'UNMET/package.json'
I already have to delete the paths: node_modules, plugins, platforms, www a lot of times.
I run:
npm install
ionic cordova plugin add cordova-plugin-local-notification
ionic cordova platform add android
and I tryied to change the order of this, but the problem don't be solved.
I'm running in a Ubuntu 18, ionic version is 4.8.0, cordova version is 9.0.0, cordova-lib 9.0.1, node version 8.10.0, npm 3.5.2.
I just run this line in terminal:
ionic cordova plugin add cordova-plugin-local-notification
my package json:
{
"name": "project-name",
"version": "0.0.1",
"author": "Ionic Framework",
"homepage": "http://ionicframework.com/",
"private": true,
"scripts": {
"android": "ionic cordova run android",
"start": "ionic-app-scripts serve",
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"lint": "ionic-app-scripts lint",
"buildAndroid": "ionic cordova build android --aot --minifyjs --minifycss"
},
"dependencies": {
"#angular/animations": "5.2.11",
"#angular/common": "5.2.11",
"#angular/compiler": "5.2.11",
"#angular/compiler-cli": "5.2.11",
"#angular/core": "5.2.11",
"#angular/fire": "^5.1.1",
"#angular/forms": "5.2.11",
"#angular/http": "5.2.11",
"#angular/platform-browser": "5.2.11",
"#angular/platform-browser-dynamic": "5.2.11",
"#ionic-native/background-geolocation": "^4.20.0",
"#ionic-native/base64": "^4.20.0",
"#ionic-native/camera": "^4.20.0",
"#ionic-native/core": "~4.18.0",
"#ionic-native/crop": "^4.20.0",
"#ionic-native/facebook": "^4.20.0",
"#ionic-native/geolocation": "^4.20.0",
"#ionic-native/google-plus": "^4.20.0",
"#ionic-native/local-notifications": "^4.20.0",
"#ionic-native/location-accuracy": "^4.20.0",
"#ionic-native/social-sharing": "^4.20.0",
"#ionic-native/splash-screen": "~4.18.0",
"#ionic-native/sqlite": "^4.20.0",
"#ionic-native/status-bar": "~4.18.0",
"#ionic/storage": "2.2.0",
"#mauron85/cordova-plugin-background-geolocation": "3.0.3",
"brmasker-ionic-3": "^1.6.3",
"com-badrit-base64": "^0.2.0",
"cordova-plugin-badge": "^0.8.8",
"cordova-plugin-camera": "^4.0.3",
"cordova-plugin-crop": "^0.4.0",
"cordova-plugin-device": "^2.0.2",
"cordova-plugin-geolocation": "4.0.2",
"cordova-plugin-googleplus": "7.0.2",
"cordova-plugin-ionic-keyboard": "^2.1.3",
"cordova-plugin-ionic-webview": "^3.1.2",
"cordova-plugin-local-notification": "0.9.0-beta.2",
"cordova-plugin-request-location-accuracy": "2.3.0",
"cordova-plugin-splashscreen": "^5.0.2",
"cordova-plugin-statusbar": "^2.4.2",
"cordova-plugin-whitelist": "^1.3.3",
"cordova-plugin-x-socialsharing": "5.4.7",
"cordova-sqlite-storage": "^3.2.0",
"es6-promise-plugin": "4.2.2",
"firebase": "^5.8.4",
"ionic-angular": "3.9.3",
"ionicons": "3.0.0",
"ngx-multilingual": "0.0.3",
"rxjs": "5.5.11",
"sw-toolbox": "3.6.0",
"zone.js": "0.8.29"
},
"devDependencies": {
"#ionic/app-scripts": "3.2.1",
"#ionic/lab": "1.0.20",
"typescript": "~2.6.2"
},
"description": "An Ionic project",
"cordova": {
"plugins": {
"cordova-plugin-whitelist": {},
"cordova-plugin-statusbar": {},
"cordova-plugin-device": {},
"cordova-plugin-splashscreen": {},
"cordova-plugin-ionic-webview": {
"ANDROID_SUPPORT_ANNOTATIONS_VERSION": "27.+"
},
"cordova-plugin-ionic-keyboard": {},
"cordova-sqlite-storage": {},
"com-badrit-base64": {},
"cordova-plugin-camera": {
"ANDROID_SUPPORT_V4_VERSION": "27.+"
},
"cordova-plugin-crop": {},
"cordova-plugin-mauron85-background-geolocation": {
"GOOGLE_PLAY_SERVICES_VERSION": "11+",
"ANDROID_SUPPORT_LIBRARY_VERSION": "26+",
"ICON": "#mipmap/icon",
"SMALL_ICON": "#mipmap/icon",
"ACCOUNT_NAME": "#string/app_name",
"ACCOUNT_LABEL": "#string/app_name",
"ACCOUNT_TYPE": "$PACKAGE_NAME.account",
"CONTENT_AUTHORITY": "$PACKAGE_NAME"
},
"cordova-plugin-googleplus": {
"PLAY_SERVICES_VERSION": "11.8.0"
},
"cordova-plugin-geolocation": {
"GEOLOCATION_USAGE_DESCRIPTION": "Para pegar as melhores promoções"
},
"cordova-plugin-request-location-accuracy": {
"PLAY_SERVICES_LOCATION_VERSION": "16.+"
},
"cordova-plugin-x-socialsharing": {
"ANDROID_SUPPORT_V4_VERSION": "24.1.1+"
},
"cordova-plugin-local-notification": {}
},
"platforms": [
"android"
]
}
}
But every plugin throw this error.
I just need to install plugins in my app again.
Just update npm and you'll be able to build again :)
I installed cordova power management plugin into my ionic application. Following the usage guidance "https://ionicframework.com/docs/native/power-management#installationenter link description here", I import the class as below:
import { PowerManagement } from '#ionic-native/power-management/ngx';
but, when build this ionic app, got the error:
Cannot find module '#ionic-native/power-management/ngx'
Why this error appears? How to fix it?
I try to import the class with removing the ngx module, then error disappears:
import { PowerManagement } from '#ionic-native/power-management';
my package.json file is:
{
"name": "ionicapp",
"version": "0.0.1",
"author": "Ionic Framework",
"homepage": "http://ionicframework.com/",
"private": true,
"scripts": {
"start": "ionic-app-scripts serve",
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"lint": "ionic-app-scripts lint"
},
"dependencies": {
"#angular/animations": "5.2.11",
"#angular/common": "5.2.11",
"#angular/compiler": "5.2.11",
"#angular/compiler-cli": "5.2.11",
"#angular/core": "^5.2.11",
"#angular/forms": "5.2.11",
"#angular/http": "5.2.11",
"#angular/platform-browser": "5.2.11",
"#angular/platform-browser-dynamic": "5.2.11",
"#angular/router": "^6.1.9",
"#ionic-native/background-geolocation": "^4.16.0",
"#ionic-native/background-mode": "^4.20.0",
"#ionic-native/ble": "^4.12.0",
"#ionic-native/bluetooth-serial": "^4.12.2",
"#ionic-native/camera": "4.3.3",
"#ionic-native/core": "^4.12.2",
"#ionic-native/geolocation": "^4.12.0",
"#ionic-native/google-maps": "^4.12.0",
"#ionic-native/launch-navigator": "^4.15.0",
"#ionic-native/native-storage": "^4.12.0",
"#ionic-native/network": "^4.12.2",
"#ionic-native/network-interface": "^4.12.2",
"#ionic-native/power-management": "^4.20.0",
"#ionic-native/splash-screen": "~4.11.0",
"#ionic-native/sqlite": "^4.12.2",
"#ionic-native/status-bar": "^4.11.0",
"#ionic/storage": "^2.1.3",
"#ngx-translate/core": "8.0.0",
"#ngx-translate/http-loader": "^2.0.0",
"#types/google-maps": "^3.2.0",
"#types/googlemaps": "^3.30.12",
"an": "0.0.8",
"angularfire2": "^5.0.2",
"chart.js": "^2.7.2",
"cordova-android": "7.1.0",
"cordova-plugin-actionsheet": "^2.3.3",
"cordova-plugin-background-mode": "git+https://github.com/tushe/cordova-plugin-background-mode.git",
"cordova-plugin-ble-central": "^1.2.2",
"cordova-plugin-bluetooth-serial": "^0.4.7",
"cordova-plugin-compat": "^1.2.0",
"cordova-plugin-device": "^2.0.2",
"cordova-plugin-dialogs": "^2.0.1",
"cordova-plugin-geolocation": "^4.0.1",
"cordova-plugin-googlemaps": "^2.4.2",
"cordova-plugin-ionic-keyboard": "^2.1.2",
"cordova-plugin-ionic-webview": "^2.1.0",
"cordova-plugin-mauron85-background-geolocation": "^3.0.0-alpha.43",
"cordova-plugin-nativestorage": "^2.3.2",
"cordova-plugin-network-information": "^2.0.1",
"cordova-plugin-networkinterface": "^2.0.0",
"cordova-plugin-powermanagement-orig": "^1.1.2",
"cordova-plugin-splashscreen": "^5.0.2",
"cordova-plugin-statusbar": "^2.4.2",
"cordova-plugin-whitelist": "^1.3.3",
"cordova-sqlite-storage": "^2.4.0",
"firebase": "^5.5.3",
"ionic-angular": "3.9.2",
"ionic-native": "4.1.1",
"ionicons": "3.0.0",
"ng2-charts": "^1.6.0",
"rxjs": "5.5.11",
"sw-toolbox": "3.6.0",
"uk.co.workingedge.phonegap.plugin.launchnavigator": "^4.2.2",
"zone.js": "0.8.26",
"at.gofg.sportscomputer.powermanagement": "~1.1.2"
},
"devDependencies": {
"#ionic/app-scripts": "^3.2.0",
"#mauron85/cordova-plugin-background-geolocation": "^3.0.0-alpha.4",
"typescript": "~2.6.2"
},
"description": "An Ionic project",
"cordova": {
"plugins": {
"cordova-plugin-ble-central": {},
"cordova-plugin-whitelist": {},
"cordova-plugin-device": {},
"cordova-plugin-splashscreen": {},
"cordova-plugin-ionic-webview": {},
"cordova-plugin-ionic-keyboard": {},
"cordova-plugin-geolocation": {
"GEOLOCATION_USAGE_DESCRIPTION": "To locate you"
},
"cordova-plugin-mauron85-background-geolocation": {
"GOOGLE_PLAY_SERVICES_VERSION": "11+",
"ANDROID_SUPPORT_LIBRARY_VERSION": "23+",
"ALWAYS_USAGE_DESCRIPTION": "App requires background tracking enabled",
"MOTION_USAGE_DESCRIPTION": "App requires motion detection"
},
"cordova-plugin-nativestorage": {},
"cordova-sqlite-storage": {},
"cordova-plugin-statusbar": {},
"cordova-plugin-bluetooth-serial": {},
"cordova-plugin-network-information": {},
"cordova-plugin-networkinterface": {},
"uk.co.workingedge.phonegap.plugin.launchnavigator": {
"OKHTTP_VERSION": "3.+"
},
"cordova-plugin-background-mode": {},
"at.gofg.sportscomputer.powermanagement": {}
},
"platforms": [
"android"
]
}
}
Use ngx if your Angular version is >=6
You seem to be using the wrong plugin version. Correct your error by following the steps mentioned below
Check your project type in ionic.config.json file.
If the type is "ionic-angular", then install 4 version.
ionic cordova plugin add cordova-plugin-powermanagement-orig
npm install #ionic-native/power-management#4
If the type is "angular", then install the latest version
ionic cordova plugin add cordova-plugin-powermanagement-orig
npm install #ionic-native/power-management
Note:
Add ngx at the end of import only if you are using Angular 6 or 6+
import { PowerManagement } from '#ionic-native/power-management/ngx';
if not remove ngx from the import both in app.module.ts and app.component.ts
import { PowerManagement } from '#ionic-native/power-management';
Refencence:https://github.com/ionic-team/ionic/issues/15225#issuecomment-414074074
I get couple of errors in node modules while trying to run app using ionic and cordova build . I am getting error while running ionic cordova run androidcommand on command line. I also tried updating ionic and angular to latest build still showing me same error. Can you please help solving this issue. Following is my package.json file. Please have a look.
[01:39:24] typescript: F:/Ionic apps/myApp/node_modules/#ionic/app-scripts/dist
/util/interfaces.d.ts, line: 1
Cannot find type definition file for 'node'.
L1: import { CompilerHost, CompilerOptions, Program } from 'typescript';
L2: import { FileCache } from './file-cache';
[01:39:24] typescript: F:/Ionic apps/myApp/node_modules/#ionic/app-scripts/dist
/util/interfaces.d.ts, line: 131
Cannot find name 'Buffer'.
L130: writeFile(filePath: string, fileContent: Buffer, callback: Function)
: void;
L131: mkdirp(filePath: string, callback: Function): void;
L132: mkdir(filePath: string, callback: Function): void;
Error: Failed to transpile program
at BuildError.Error (native)
at new BuildError (F:\Ionic apps\myApp\node_modules\#ionic\app-scripts\dist\
util\errors.js:16:28)
at F:\Ionic apps\myApp\node_modules\#ionic\app-scripts\dist\transpile.js:159
:20
at transpileWorker (F:\Ionic apps\myApp\node_modules\#ionic\app-scripts\dist
\transpile.js:107:12)
at Object.transpile (F:\Ionic apps\myApp\node_modules\#ionic\app-scripts\dis
t\transpile.js:64:12)
at F:\Ionic apps\myApp\node_modules\#ionic\app-scripts\dist\build.js:109:82
[01:39:25] copy finished in 14.86 s
F:\Ionic apps\myApp>
Following is my package.json`
"name": "cricket",
"version": "0.0.1",
"author": "Ionic Framework",
"homepage": "http://ionicframework.com/",
"private": true,
"scripts": {
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"lint": "ionic-app-scripts lint",
"ionic:build": "ionic-app-scripts build",
"ionic:serve": "ionic-app-scripts serve"
},
"dependencies": {
"#angular/animations": "5.2.9",
"#angular/common": "5.2.9",
"#angular/compiler": "5.2.9",
"#angular/compiler-cli": "5.2.9",
"#angular/core": "5.2.9",
"#angular/forms": "5.2.9",
"#angular/http": "5.2.9",
"#angular/platform-browser": "5.2.9",
"#angular/platform-browser-dynamic": "5.2.9",
"#firebase/app": "^0.1.10",
"#ionic-native/core": "4.5.3",
"#ionic-native/splash-screen": "4.5.3",
"#ionic-native/status-bar": "4.5.3",
"#ionic/pro": "1.0.20",
"#ionic/storage": "^2.1.3",
"angularfire2": "^5.0.0-rc.6.0",
"cordova-android": "^6.3.0",
"cordova-plugin-device": "^2.0.1",
"cordova-plugin-firebase": "^0.1.25",
"cordova-plugin-ionic-keyboard": "^2.0.5",
"cordova-plugin-ionic-webview": "^1.2.0",
"cordova-plugin-splashscreen": "^5.0.2",
"cordova-plugin-whitelist": "^1.3.3",
"cordova-sqlite-storage": "^2.3.0",
"firebase": "^4.13.1",
"ionic-angular": "3.9.2",
"ionicons": "3.0.0",
"path": "^0.12.7",
"rxjs": "5.5.7",
"sw-toolbox": "3.6.0",
"upstox": "^1.2.3",
"zone.js": "0.8.20"
},
"devDependencies": {
"#ionic/app-scripts": "^3.1.7",
"typescript": "~2.6.2"
},
"description": "An Ionic project",
"cordova": {
"plugins": {
"cordova-plugin-firebase": {},
"cordova-sqlite-storage": {},
"cordova-plugin-whitelist": {},
"cordova-plugin-device": {},
"cordova-plugin-splashscreen": {},
"cordova-plugin-ionic-webview": {},
"cordova-plugin-ionic-keyboard": {}
}
}
}
`
I solved this issue by checking cordova-android and #ionic/app-scripts compatibility from Changelog Description
1. Install cordova-android version (6.4.0 or 6.3.0) and #ionic/app-scripts version(3.1.8)
2. Remove android platform and add it agian.
I have installed:
npm install #ionic-native/core --save
ionic cordova plugin add cordova-plugin-speechrecognition --save
and I can even see it in package.json but when I am adding it in app.module.ts I am getting this error:
Cannot find module '#ionic-native/speech-recognition'
I do not understand what to do, I have removed it and added it many times but nothing is working.
My package.json code is below
{
"name": "quicktask",
"version": "0.0.1",
"author": "Ionic Framework",
"homepage": "http://ionicframework.com/",
"private": true,
"scripts": {
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"lint": "ionic-app-scripts lint",
"ionic:build": "ionic-app-scripts build",
"ionic:serve": "ionic-app-scripts serve"
},
"dependencies": {
"#angular/common": "4.4.4",
"#angular/compiler": "4.4.4",
"#angular/compiler-cli": "4.4.4",
"#angular/core": "4.4.4",
"#angular/forms": "4.4.4",
"#angular/http": "4.4.4",
"#angular/platform-browser": "4.4.4",
"#angular/platform-browser-dynamic": "4.4.4",
"#ionic-native/core": "^4.3.2",
"#ionic-native/firebase": "^4.4.2",
"#ionic-native/in-app-browser": "^4.5.2",
"#ionic-native/splash-screen": "4.3.2",
"#ionic-native/status-bar": "4.3.2",
"#ionic/storage": "^2.0.1",
"cordova-android": "^6.2.3",
"cordova-browser": "5.0.1",
"cordova-plugin-device": "^1.1.4",
"cordova-plugin-firebase": "^0.1.24",
"cordova-plugin-inappbrowser": "^1.7.2",
"cordova-plugin-ionic-webview": "^1.1.11",
"cordova-plugin-speechrecognition": "^1.2.0",
"cordova-plugin-splashscreen": "^4.0.3",
"cordova-plugin-whitelist": "^1.3.1",
"cordova-sqlite-storage": "^2.1.2",
"ionic-angular": "3.8.0",
"ionic-plugin-keyboard": "^2.2.1",
"ionicons": "3.0.0",
"rxjs": "5.4.3",
"sw-toolbox": "3.6.0",
"time-ago-pipe": "^1.2.1",
"zone.js": "0.8.18"
},
"devDependencies": {
"#ionic/app-scripts": "3.0.1",
"typescript": "2.3.4"
},
"description": "An Ionic project",
"cordova": {
"plugins": {
"cordova-plugin-device": {},
"cordova-plugin-ionic-webview": {},
"cordova-plugin-splashscreen": {},
"cordova-plugin-whitelist": {},
"ionic-plugin-keyboard": {},
"cordova-plugin-firebase": {},
"cordova-sqlite-storage": {},
"cordova-plugin-inappbrowser": {},
"cordova-plugin-speechrecognition": {}
},
"platforms": [
"android",
"browser"
]
}
}
As per the docs, here, you will need to run npm install --save #ionic-native/speech-recognition in addition to installing the cordova plugin
I am using ionic 2.
I create new project
ionic start Ismart --v2
The project was successfully created.
I tried to run the project using ionic serve
I am getting this err
Cannot find namespace 'moment'
Here is my Package.Json
{
"name": "ionic-hello-world",
"version": "0.0.0",
"author": "Ionic Framework",
"homepage": "http://ionicframework.com/",
"private": true,
"scripts": {
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"ionic:build": "ionic-app-scripts build",
"ionic:serve": "ionic-app-scripts serve"
},
"dependencies": {
"#angular/common": "4.0.2",
"#angular/compiler": "4.0.2",
"#angular/compiler-cli": "4.0.2",
"#angular/core": "4.0.2",
"#angular/forms": "4.0.2",
"#angular/http": "4.0.2",
"#angular/platform-browser": "4.0.2",
"#angular/platform-browser-dynamic": "4.0.2",
"#ionic-native/core": "3.4.2",
"#ionic-native/splash-screen": "3.4.2",
"#ionic-native/status-bar": "3.4.2",
"#ionic/storage": "2.0.1",
"ionic-angular": "3.1.0",
"ionicons": "3.0.0",
"rxjs": "5.1.1",
"sw-toolbox": "3.4.0",
"zone.js": "^0.8.5"
},
"devDependencies": {
"#ionic/app-scripts": "1.3.6",
"typescript": "~2.2.1"
},
"cordovaPlugins": [
"cordova-plugin-whitelist",
"cordova-plugin-console",
"cordova-plugin-statusbar",
"cordova-plugin-device",
"cordova-plugin-splashscreen",
"ionic-plugin-keyboard"
],
"cordovaPlatforms": [],
"description": "ISmartpremises: An Ionic project"
}
How can i fix this issue...
Kindly advice me,
Thanks
I cannot see any issue in your package.json file.I think you have forgotten to change the directory.
You can try as shown below.
d:\ionic2 > ionic start Ismart blank --v2
d:\ionic2\Ismart> ionic serve