Document

Environment

Git : https://github.com/steveleetn91/vn-native-2

Please install by docs , no use git clone . After install library depenment you should restart device. All command line will be run on Git Bash

Name Description
Nodejs https://nodejs.org/en/download
JDK8 https://www.oracle.com/java/technologies/javase-jdk8-downloads.html
Git bash https://gitforwindows.org
Xcode Apple Store
Android Studio Android Studio Webasite
Visual Studio 2015

Download at here https://my.visualstudio.com/Downloads?q=visual%20studio%202015&wt.mc_id=o~msft~vscom~older-downloads.

Then you need download windows 10 sdk, please no change path install. You need select options related WINJS.

NPM npm i -g vn-native-2
Note You need install all software before run NPM . If has problem of permission then let try use sudo

Create project

Open new command line window and run : vn-native-2-project --name=ilovevn --packageId=com.ilovevn --appName="I Love Vn" --force

Please install by docs , no use git clone . After install library depenment you should restart device. All command line will be run on Git Bash

Option Description
info Show infomation project
name Directory name to create project
packageId App package id
appName App name
Note

Macos & Linux :

- If has problem of permission then let try use sudo .

- After you set permission for project to read and write file sudo chmod -R 777 ./directory-name

- If in macos sudo chown -R $USER:$(id -gn $USER) /Users/username/.config. Change username by account using computer .

npm i -g vn-native-2

OS

Action Description
Import

import VnNativeCore from 'vn-native-js/VnNativeCore'; let os = VnNativeCore.os();

Out AndroidOS | BlackBerryOS | PalmOS | SymbianOS | WindowsMobileOS | WindowsPhoneOS | iOS | iPadOS | MeeGoOS | MaemoOS | JavaOS | webOS | badaOS | BREWOS

Add platform

Go to root project and run : vn-native-2-platform --platform=ios --action=add

Option Description
platform

select platform [ios|android|osx|windows|browser]

action

select action [add|remove]

Start server and platform

Go to root project and run, after start server you can visit in the browser at Port : 9000 . Server and platform is different vn-native-2-server --start=server . If you need run on the real device , so change localhost to ip of config.json , don't forget restart server

Option Description
start

select platform server|ios|android|osx|windows|browser

note

You should run server first after open new command line window and start platform ios|android|osx|windows|browser . If has problem of IOS-SIM, so please check permission note at Environment then run again