Preview 2.0 is now in Public Beta!
Read the Announcement
Note: You are on the beta version of our docs. This is a work in progress and may contain broken links and pages.

You can develop NativeScript apps in any text editor or IDE you prefer.

VS Code

Most of the NativeScript team prefers to use VS Code from Microsoft as their editor for NativeScript apps. Some reasons we use VS Code:

  • Visual Studio Code has excellent support for TypeScript.
  • Visual Studio Code gives you the ability to debug JavaScript and TypeScript code directly in your editor. The NativeScript team maintains an official NativeScript Visual Studio Code extension that enables step debugging for NativeScript apps.
  • Visual Studio Code is a fast, modern editor that Microsoft updates frequently.
  • Visual Studio Code is available for Windows, macOS, and Linux.
  • Microsoft backs Visual Studio Code; therefore, you can feel confident that the editor will continue to be supported in the future.

If you do choose to try Visual Studio Code, let's look at one tip you might find useful as you develop NativeScript apps.

  • The code command

After you install Visual Studio Code, you can open projects using the editor's FileOpen menu option, but there's an alternative option that works far better for command-line-based projects like NativeScript: the code command.

The code command runs in your command-line or terminal, and it works just like the ns command does for NativeScript apps. Visual Studio Code installs the code command by default on Windows on Linux, but on macOS, there's one manual step you must perform.

Once set up, you can type code . in your terminal to open the files in your current folder for editing. For example, you could use the following sequence of command to create a new NativeScript app and open it for editing.

cli
ns create MyNewApp
cd MyNewApp
code .

WebStorm

If you're a WebStorm user, check out this popular community-written plugin that adds many NativeScript-related features.

Next steps

  • NativeScripting
    • The third-party NativeScripting site has many video courses to teach you everything you need to know about NativeScript, including a collection of free courses to help you get started.
  • Code Samples
    • The NativeScript team provides a collection of high-quality code samples you can add to your applications. Perusing the code samples is a great way to get familiar with what NativeScript can do, as well as find the code you can use on your next app.
Previous
Styling