How to Installing NodeJS at Your Phone
Yes, Like the Title said. I will teach you How to install node js at your phone.
Requirements:
- x64 Phone,
- Android 7.1+,
- and your Termux
To Do before Installation
- Install Termux at Playstore
- Update all Package inside Termux by Executing
apt update && apt upgrade
- Make your Termux can access your Internal Storage by executing
termux-setup-storage
NOTICE: Your Default$HOME
is at/data/data/com.termux/files/home
. To accessing Them, Use FX File Manager. - You were ready now.
Install Those thing.
- NodeJS,
- Git,
- Python,
- GNU Nano / VIM
Installing NodeJS
Install Node to your Termux
pkg install nodejs
# Or, If you want install NodeJS v12 LTS,
pkg install nodejs-lts
# Launch node!
node
# For some reason, Node v15 is not supported in Termux.
# Termux Team is still working at it. Please Be Patient.
Installing git
By default, Termux is not Install git
package.
If you want, execute:
pkg install git
NOTE: GIT IS VERY REQUIRED
Installing Python
Sometime, Python is required at some npm package (Example is quick.db). By default, python is not installed like Linux Does. To installing them to your Termux, Execute:
pkg install python python2
# Launch Python
python
# Launch Python2
python2
# Launch Python3
python3 # Auto installed after executing `pkg install python`.
Installing nano
Edit your Files using Nano.
pkg install nano
# Edit / Create new File
nano <filename/non-listed filename>
Installing VIM
Edit your Files using VIM
pkg install vim
# Learn how to using VIM at Termux
vimtutor
Getting Started
- Create your Node Project Folder by executing:
mkdir folder-name
# If you want a Space foldername,
mkdir "folder name"
# For entering to Spaced Foldername, Execute `cd "folder name"`.
- Do
npm init -y
- Edit your
index.js
or main node file - Execute it.
Accessing your Termux File
- Download FX File Manager at Playstore
- Open the App, And Tap the 3 Vertical Dot, Then, Tap this:
-
After That, Tap:
-
Your Termux Storage in FX must looks like this:
-
You can manage your Termux Storage at FX now.