NativeScript project doesn’t work after switching git branch

Telerik NativeScript tns CLI generates iOS and android project in platform/ios and platform/android folders respectively. If we switch between Git branches it may stop working

In this case you can remove existing platforms by following command

tns platform remove iOS and/or tns platform remove android

Now to make work properly you can either add your need platform by

tns platform add iOS or

tns platform add android

or you can add Both the platforms by

tns install

Now you can run project by

tns run ios or tns run android

Originally published at Nikhil Gohil.

Like what you read? Give Nikhil Gohil a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.