• This repository has been archived on 17/Nov/2022
  • Stars
    star
    446
  • Rank 97,888 (Top 2 %)
  • Language
    CSS
  • License
    Apache License 2.0
  • Created over 10 years ago
  • Updated about 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Documentation, API reference, and code snippets for NativeScript

NativeScript Documentation (v7 and below)

Home of the NativeScript documentation content that lives at http://docs.nativescript.org. Start contributing today!

What’s In This Document

Contributing

The NativeScript documentation is completely open-source and we love contributions. Whether you want to fix a typo or write an entire article, the NativeScript documentation is a great way to get started contributing to an open-source project.

Don’t know where to start? Check out the list of issues with the “help wanted” label. New to git or GitHub? Join our community Slack chat and we’ll be happy to help get you up and running.

The master branch contains the most up-to-date version of the NativeScript documentation and its contents are uploaded to docs.nativescript.org. When contributing to the documentation, always create a branch for your work from master as this will facilitate easier pull request management.

Are my contributions limited to this repo only?

No, my friend. There are many other code repositories in the NativeScript world you might also be interested in contributing to:

  • nativescript-cli - This repo contains the NativeScript command-line interface, which lets you create, build, and run apps using the NativeScript framework. The CLI is written in TypeScript.

  • nativescript-angular - This repository contains the TypeScript code that integrates Angular with NativeScript.

  • nativescript-vue - This community-run project allows NativeScript to integrate with Vue.js.

  • ios-runtime - This repo contains the NativeScript iOS runtime — the code that hosts NativeScript iOS apps, and allows JavaScript code to be executed on iOS devices. The iOS runtime is written in a fun mix of C++, Objective-C, and more.

  • android-runtime - This repo contains the NativeScript Android — the code that hosts NativeScript Android apps, and allows JavaScript code to be executed on Android devices. The Android runtime is written in a fun mix of C++ and Java.

You can go check them out and help to expand their docs, add plugins to it and even fix bugs.

About Jekyll

This documentation is built using Jekyll. More info on how to control the template, table of content and the project structure, in general, can be found in the Build README

Configuration

There are two versions of the NativeScript documentation that generate similar output: nativescript and angular. The former builds the vanilla NativeScript docs at docs.nativescript.org/start/introduction, while the latter discusses Angular-specific topics at docs.nativescript.org/angular/start/introduction.

Most of the content in this repository is shared between the two environments, but occasionally you may need to add environment-specific content. When you have this need you have a few options.

  1. If you would like a page to appear in a single environment, add an environment: angular or environment: nativescript property to that page's front matter. Pages marked with an environment property will appear in a single environment, and pages not marked with an environment property will be shared across all environments.

  2. If you have a page that should appear in both environments but has different content for certain sections, you can use our built-in environment block tags. The blocks are named angular and nativescript, respectively, and can be used like this:

{% nativescript %}This paragraph appears only in the vanilla NativeScript documentation{% endnativescript %}

This paragraph appears in both environments.

{% angular %}This appears only in the Angular NativeScript documentation{% endangular %}

Local Setup

If you plan to work on a non-trivial change, you will most probably want to run the documentation locally in order to give your change a try before submitting a pull request. To provide you with this opportunity without installing a ton of libraries and loose time in configuration, we have prepared a virtual environment based on a docker image, where everything is prepared for you in advance.

Prerequisites

Docker should be installed on your machine:

The NativeScript documentation is composed from multiple repositories:

Building the docker image

Start by cloning all required git repositories in some local folder (ns-docs in the following examples):

Open a console box (Windows users should run a Git bash session!) and clone the required git repositories:

mkdir ns-docs
cd ns-docs
git clone https://github.com/NativeScript/docs.git
git clone https://github.com/NativeScript/nativescript-angular.git

Optional:

git clone https://github.com/NativeScript/NativeScript.git
git clone https://github.com/NativeScript/nativescript-sdk-examples-js.git
git clone https://github.com/NativeScript/nativescript-sdk-examples-ng.git
git clone https://github.com/NativeScript/nativescript-cli.git

git clone https://github.com/NativeScript/nativescript-ui-samples.git
git clone https://github.com/NativeScript/nativescript-ui-samples-angular.git
git clone https://github.com/NativeScript/nativescript-ui-samples-vue.git

NOTE: nativescript-ui-... are private repositories used for building the API Reference for the NativeScript UI components.
NOTE: If you have these repositories locally from previous work with the documentation, be sure to delete them and start from scratch as some old files can cause problems with the current setup.

Then, build the docker image by using the following command from the ns-docs folder:

sudo docker build -t ns-docs:1.0 docs/build

NOTE: If you received some unauthorized error, make sure you are logged into docker from the CLI. Just execute docker login and follow the instruction. One thing to have in mind is that docker username is your email, but docker ID is what you see on the top right when you log in to https://hub.docker.com. When executing docker login you need to enter your Docker ID.

Building the documentation

Start the docker image created in the previous step from the ns-docs folder:

sudo docker run --rm -t -i -v $(pwd):/root -p 9192:9192 -t ns-docs:1.0

Due to the poor performance of mounted volumes on Mac OS you may use the delegated mount strategy:

sudo docker run --rm -t -i -v $(pwd):/root:delegated -p 9192:9192 -t ns-docs:1.0

Adding content

Edit an article in some of the repositories and navigate to http://localhost:9192 on the host machine. Notice that it might take some time for the changes to be reflected in the browser.

Making changes

  • Edit some files.
  • Refresh your browser (depending on which files have been modified, it might take more or less time for the changes to take effect).

Contributors

The following is a list of all the people that have contributed to the NativeScript documentation. Thanks for your contributions!

tsonevnNickIlievtjvantolletabakovErjanGavaljins-bot

radevavakrilovrdlauerN3llhdeshevtbozhikov

mbektchievikoevskaerikruthnsndecksis0k0petekanev

hamorphisvtrifonovPlamen5kovPetyaSotirovabundyoalexziskind1

atanasovgsipacateMartoYankovsebawitaangeltsvetkovteobugslayer

ggarabedianivanbuhovlinidtopuzovtdermendjievzbranzov

EmilStoychevjasssonpetKristianDDdarindvchimevenchev

pkolevaMitko-Kerezovrosen-vladimirovjlooperboevskitgpetrov

vmutafovmanoldonevbdlb77paulpvsurduroblav96

rynoptzraikovPanayotCankovbradmartinjpennagetsetbro

tailsusitefinitystevedmccuskeyelena-pyyosifovparloti

burkehollandpelegrifelipebuenojbristoweLampeizh-m

000panthermudlabsShawnPaveltushutripathishiv19adrian-niculescu

alejonextAmitGurbaniAntonDobrevbaskarmibdjenitoofdnhkj

gbhojrajHakiershirohanablackpanther99imcgonigleignaciolarranaga

lonerzzzBjorn576jayvolrjonnysampsdigitaldrummerjLokeCarlsson

msaelicesmilejkomap7m-absNikhil22noumaans

pedromorganRazzeeerenestalderrodrigopiresTedHoppWilcoBreedt

devoto13eyal7773miroslavaivanovamtekpTsvetanMilanovajoslin103

ADmadairandfingersadamunionAjaiDubeyFustyADjenkov

Alexander-Bliznyukkondasoftamjdthe-AoG-guydevdRewMonsieurMan

gupta-ankitABoschmanBurgovbensoorajbsykbenjlin

brandonpearson23clounietonjohnCMRHDLcameronnormancelso-wo

chuckmitchellcrixxchrantsyapcwedctp-placebochrismullins

ClaudioMeinbergdotlensderskealDarkleCoreyColeejsuncy

DTV96CalibreDannyFelizdennistangDimitarTachevdiogocapeladonangel

dogabudakDrQwertySilencedyldawgezesundayezefelipebernardesFrancoisCamus

codepotatosundaygleegrgurharikrishnana2021hristoborisovhugocarreiracosta

jagadish-kbjkulubyajayoman3wcJmOkayjofftiquez

jrpooljrzjoshgkingTheOriginalJoshjpierrontjurgentreep

KsantacrkharysharpeLeandroDGlukesammymacknelsonmshanak

marablayevmrcastemarklanhamhchettigernemephxDanekDanek

realteboMitzaCodermhrabieemrmowjiLiteCatDevNatalia-Hristova

nicoegnike47oluwaseyeoimyounisOmnicouleurdeveloper82

pzanittipdvorchikpascualstromsnesdodongphuremorph3oqkdreyer

rajatraj733rakeshgiraseReshmaPDRohanTalipffxsamSamVerschueren

mastixsean-perkinssebastianovidejalkobyshauntifsimmstein

SirMaxxxDasAllFolkstadeucariolanoTaremehTechnicalSoupTetrygon

tralvesfartektdouse2l3ntonymportertrentvb

viragumathe5VladimirAmiorkovweech3rwilliamhoXorbertycherniavskyi

csjdiyewsdoorb02Ayushraj1ishandutta2007jacostaperu

jamessouthjohannbraunjyotendranarayananl23pavanserpeterennis

quintonnsaiberzsaknarakseros00shendrekbharathstevo-knievo

svalchinovtdsmithATabctrevordowdletsirayavulanyjaaidi

bangseongbeom

More Repositories

1

NativeScript

⚡ Empowering JavaScript with native platform APIs. ✨ Best of all worlds (TypeScript, Swift, Objective C, Kotlin, Java). Use what you love ❤️ Angular, Capacitor, Ionic, React, Solid, Svelte, Vue with: SwiftUI, Jetpack Compose, Flutter and you name it compatible.
TypeScript
23,002
star
2

nativescript-angular

Integrating NativeScript with Angular
TypeScript
1,213
star
3

nativescript-cli

Command-line interface for building NativeScript apps
JavaScript
1,037
star
4

android

NativeScript for Android using v8
C++
521
star
5

sample-Groceries

🍏 🍍 🍓 A NativeScript-built iOS and Android app for managing grocery lists
TypeScript
484
star
6

nativescript-marketplace-demo

NativeScript kitchen sink demo. All of NativeScript’s functionality in one app.
TypeScript
325
star
7

ios-jsc

NativeScript for iOS using JavaScriptCore
JavaScript
295
star
8

nativescript-sdk-examples-ng

NativeScript and Angular code samples.
TypeScript
292
star
9

nativescript-app-templates

Monorepo for NativeScript app templates
TypeScript
222
star
10

plugins

@nativescript plugins to help with your developments.
TypeScript
190
star
11

nativescript-schematics

nativescript, mobile, schematics, angular
TypeScript
186
star
12

tailwind

Makes using TailwindCSS in NativeScript a whole lot easier!
JavaScript
150
star
13

ios

NativeScript for iOS and visionOS using V8
JavaScript
130
star
14

theme

@nativescript/theme
SCSS
127
star
15

nativescript-app-sync

♻️ Update your app without going through the app store!
C
125
star
16

push-plugin

Contains the source code for the Push Plugin.
Objective-C
123
star
17

sample-ng-todomvc

Angular2 + NativeScript TodoMVC example
115
star
18

nativescript-imagepicker

Imagepicker plugin supporting both single and multiple selection.
TypeScript
104
star
19

nativescript-background-http

Background Upload plugin for the NativeScript framework
TypeScript
101
star
20

nativescript-dev-webpack

A package to help with webpacking NativeScript apps.
JavaScript
97
star
21

nativescript-camera

NativeScript plugin to empower using device camera.
TypeScript
91
star
22

android-dts-generator

A tool that generates TypeScript declaration files (.d.ts) from Jars
Java
90
star
23

canvas

C++
88
star
24

nativescript-facebook

NativeScript plugin, wrapper of native Facebook SDK for Android and iOS
TypeScript
78
star
25

nativescript-dev-appium

A package to help with writing and executing e2e Appium tests in NativeScript apps
TypeScript
69
star
26

windows-runtime

NativeScript Runtime for the Universal Windows Platform
C
64
star
27

sample-android-background-services

Using Android Background Services in NativeScript
JavaScript
63
star
28

nx

NativeScript for Nx.
TypeScript
61
star
29

firebase

Modular Firebase 🔥 implementation for NativeScript. Supports both iOS & Android platforms for all Firebase services.
TypeScript
54
star
30

android-v8

Contains the Google's V8 build used in android runtime.
Shell
54
star
31

nativescript-fresco

This repository holds the NativeScript plugin that exposes the functionality of the Fresco image library to NativeScript developers.
TypeScript
52
star
32

nativescript-sdk-examples-js

JavaScript
51
star
33

sample-Angular2

49
star
34

nativescript-canvas

HTML5-like 2D and WebGL canvas implementation for NativeScript
C++
48
star
35

plugin-seed

Build NativeScript Plugins Fast ⚡
TypeScript
44
star
36

nativescript-dev-sass

SASS CSS pre-processor for NativeScript projects
JavaScript
44
star
37

angular

NativeScript for Angular
TypeScript
40
star
38

capacitor

NativeScript for Capacitor
TypeScript
37
star
39

sample-ios-background-execution

Running Custom Background Tasks with NativeScript
JavaScript
36
star
40

worker-loader

JavaScript
36
star
41

functional-tests-core

Appium based framework for testing Android and iOS native mobile apps.
Java
36
star
42

nativescript-app-encryption

This plugin encrypts all your app/**.js files during a release build. In experimental state.
JavaScript
35
star
43

tutorials

Project source to tutorials presented here: https://docs.nativescript.org/tutorial/
TypeScript
34
star
44

rfcs

RFCs for NativeScript and related tooling
33
star
45

payments

In-App Purchase, Subscriptions, Google Pay, Apple Pay for NativeScript
TypeScript
33
star
46

capacitor-docs

JavaScript
31
star
47

sample-iOS-Profiling

Performance comparison of popular cross-platform frameworks
JavaScript
29
star
48

docs-v8

HTML
29
star
49

sample-Android-Widgets

JavaScript
29
star
50

animation-demo

A sample app demonstrating different kinds of animations achieved with CSS, keyframes and NativeScript.
TypeScript
29
star
51

nativescript-datetimepicker

Plugin with date and time picking fields
TypeScript
26
star
52

nativescript-ui-charts

NativeScript wrapper around HiCharts library
TypeScript
26
star
53

nativescript-remote-builds

A NativeScript plugin for remote builds when running and publishing NativeScript apps without env setup.
JavaScript
26
star
54

login-tab-navigation-ng

{N} Angular with login and tabs page navigation
JavaScript
26
star
55

mlkit

TypeScript
24
star
56

workshop

NativeScript! And workshops! 🎉
TypeScript
23
star
57

nativescript-picker

Plugin that provides a custom TextField which lets you pick a value from a list opened in a modal popup.
TypeScript
22
star
58

nativescript-app-sync-server

JavaScript
22
star
59

sample-ImageUpload

An integration of nativescript-image-picker and nativescript-background-http
JavaScript
22
star
60

nativescript-cordova-support

A NativeScript plugin which enables you to use cordova plugins inside your NativeScript-based project.
Java
21
star
61

nativescript-dev-typescript

TypeScript support for NativeScript projects
JavaScript
20
star
62

sample-ios-embedded

Embedding the NativeScript for iOS runtime in an existing app
Objective-C
19
star
63

nativescript-angular-guide

A guide to building apps with NativeScript and Angular 2
HTML
17
star
64

summer-of-nativescript

Resources for the summer of NativeScript
JavaScript
17
star
65

visionos-hello-world

Vision Pro 🥽 Hello World tutorial with NativeScript using various flavors - Angular, React, Solid, Svelte, TypeScript and Vue.
Swift
17
star
66

sample-tvOS

A proof of concept app with the NativeScript runtime running on Apple TV
JavaScript
17
star
67

vue-x-platforms

Vue running on Web, iOS, Android and Vision Pro.
Vue
16
star
68

runtime-node-api

An embeddable, engine-agnostic NativeScript runtime based on Node-API
C
16
star
69

artwork

NativeScript artwork
JavaScript
15
star
70

playground-feedback

Feedback for NativeScript Playground
15
star
71

ios-device-lib

Allows interaction with iOS devices.
C++
15
star
72

nativescript-hook

Helper module for installing hooks into NativeScript projects
JavaScript
14
star
73

android-compose-example

@nativescript/jetpack-compose Example 🚀📓♥️
Kotlin
14
star
74

nativescript-ios-imessages

Simple app extension that interact with the Messages app
C
14
star
75

NativeScript-NEXT-Workshop

Workshop material for teaching NativeScript
13
star
76

playground-tutorials

NativeScript Playground tutorials content
13
star
77

nativescript-unit-test-runner

TypeScript
13
star
78

docs

The NativeScript Docs!
TypeScript
12
star
79

tns-core-modules-widgets

Repo for widgets used in NativeScript modules
Java
12
star
80

demo-workers

JavaScript
12
star
81

examples-best-practices

TypeScript
11
star
82

sample-iOS-HealthKit

This sample shows a simple use of the iOS HealthKit APIs.
JavaScript
11
star
83

sample-native-module

Sample native module for NativeScript
C++
11
star
84

functional-tests-demo

XSLT
10
star
85

ns-ng-animation-examples

TypeScript
10
star
86

pbxproj-dom

pbxproj object model
TypeScript
10
star
87

ios-metadata-generator

Visit the iOS Runtime repo for instructions and related issues
C++
10
star
88

nativescript-app-sync-web

Web client for the codepush server
JavaScript
9
star
89

ios-sim-portable

A Node.js command-line utility to launch an iOS application bundle (.app) in the Xcode iOS Simulator
TypeScript
9
star
90

nativescript-dev-coffeescript

JavaScript
9
star
91

nativescript-doctor

Library that helps identifying if the environment can be used for development of {N} apps.
TypeScript
8
star
92

storybook

📚 Storybook for NativeScript 📲
TypeScript
8
star
93

nativescript-dev-jade

JavaScript
8
star
94

eslint-plugin

ESLint plugin for NativeScript projects.
TypeScript
8
star
95

nativescript-cli-tests

NativeScript CLI Integration Tests
Python
8
star
96

androidx-migration-tool

JavaScript
8
star
97

nativescript-dev-debugging

This package allows the developer of a NativeScript plugin to use a workflow that allows to debug both the native iOS (objective-c, swift) and Android (Java) code and the wrapper TypeScript/JavaScript code of the plugin used inside an NativeScript application. This is a powerful "tool" which will rebuild both the native framework (iOS) and arr files (Android) and the TypeScript/JavaScript code of your NativeScript plugin.
JavaScript
8
star
98

widget-example

iOS Home Screen Widget Example
TypeScript
8
star
99

sample-iOS-CameraApp

In this sample we are demonstrating how you can write platform specific code with NativeScript. We are building iOS only app which uses the latest iOS8 camera APIs.
JavaScript
7
star
100

flutter-example

Using Flutter with NativeScript including Bluetooth integration via @nativescript-community/ble
Dart
7
star