When I'm trying to create a simple ionic app with 'ionic start' command, I see that ionic downloads a base app and the template indicated, but then I see 'Installing npm packages...' and it that never ends it's process (I have waited hours).
Ionic creates the myapp folder with files within it, but I don't know if it finally creates the ionic app to work with. If I put 'ionic serve' there is nothing on screen, even if I choose the tabs template.. or an error 'couldn't find ionic.config.json file'
is it a firewall issue? anyone has faced with this?
You must update your ionic to beta version using:
npm install -g ionic#beta
Related
When I install for example the Insomnia plugin the Capacitor way like so:
npm install cordova-plugin-insomnia
npm install #ionic-native/insomnia
ionic cap sync
It still requires me to install the cordova plugin like this:
ionic cordova plugin add cordova-plugin-insomnia
In order to work. Otherwise it says: plugin_not_installed
My steps to make it work are:
Step 1: Add Insomnia to providers (#ionic-native/insomnia/ngx)
Step 2: Inject Insomnia within the constructor private insomnia: Insomnia
Am I forgetting something or do I just really need to ionic cordova plugin add for plugins that are not fully supported yet?
Probably obvious for most but just in case someone else might face this problem..
When you use capacitor you shouldn't start your server with ionic cordova run or ionic cordova build anymore.
Obviously you need to start it this way for livereload:
ionic cap run android -l --external
ionic cap run ios -l --external
That is because your application is using cordova and not capacitor..
Remove your platforms folder, and just to make sure and remove unnecessary cordova files which will increase your app size, remove cordova-android and cordova-ios from your package.json.. You do not need that for running your app based on capacitor.
Then, run this command.
ionic build
npx cap add android
npx cap add ios
For each successive build, in case you add or remove a plugin, use npx cap sync
Otherwise use npx cap copy
Reference Docs
As ionic5 is now released, so now when I use this command ionic start myApp blank --type=angular ionic5 app is created, I can confirm this from ionic info command, I am wondering how can I create ionic4 project. The reason behind creating ionic4 project is I have one app in ionic3 and I want to upgrade that app to first in ionic4 and then to ionic5 instead of directly going to latest one because I don't yet know the breaking changes in ionic5 yet and I haven't yet worked on it as well
okay, I got ionic4 app by first creating project with command sudo ionic start myApp blank --type=angular and then when project was created, then using sudo npm i #ionic/angular#^4.0.0 inside app directory to update the ionic info, this can be confirmed both via package.json and ionic info command
in my old ionic version i was able to run and install ionic properly.
but while creating a new project in ionic i get this error
please help me out.
C:\>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: sumith
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: blank
√ Preparing directory .\sumith - done!
√ Downloading and extracting blank starter - done!
Installing dependencies may take several minutes.
* IONIC DEVAPP *
Speed up development with the Ionic DevApp, our fast, on-device testing mobile app
> npm i
npm WARN deprecated circular-json#0.5.9: CircularJSON is in maintenance
only, flatted is its successor.
[ ..............] / fetchMetadata: sill resolveWithNewModule
punycode#2.1.1 checking installable status
set NODE_TLS_REJECT_UNAUTHORIZED=0 before running ionic start.
I am facing a problem in ionic to start a new ionic project or serve ionic project while Internet connection in on.
In Command Prompt no error come but CLI break after a few seconds. But without an Internet connection it works perfectly, mean without an Internet connection I can serve the ionic project (ionic serve). But to start a new project we have to connect our laptop to the Internet connection and with the connection, I have this problem. I have reinstalled the ionic but still, I'm facing this problem.
This is the image of process of ionic serve with Internet connection
Problem Solved!
first we have to uninstall ionic
npm uninstall -g ionic cordova
still ionic has not completely uninstalled. To do the same we have to delete all ionic files in our windows drive (Local Disk :c).
then we have to uninstall nodejs from control panel.
still node and npm has not uninstalled completely so we also have to delete all node and npm files from c drive.
now install nodejs recommended and the ionic
npm install -g ionic cordova
It will work now....
The server doesn't start up. You should get a lot more processes showing after the
webpack started ...
like sass, postprocess, lint, build etc.
To find out the possible error you can use the verbose switch which may help show what the error is.
$ ionic serve --verbose
Please try that and see what the output is.
I am new to Ionic, I have installed my ionic to C:\Users\myname, now I don't install ionic under user name folder, because it make my folder mess and i want to put them to one directory, meanwhile, i don't want to uninstall my ionic and corvoda and install them again !
does anyone have any solution for this.
Thanks
Install ionic and cordova using npm repository globally.First install node.js and follow the below instructions https://ionicframework.com/getting-started/