Skip to main content

Installation Guide

This guide covers everything you need to set up a complete development environment for CryptoTracker, including platform-specific requirements for iOS and Android development.

Prerequisites

Before installing CryptoTracker, ensure you have the following installed on your system:

Required Software

CryptoTracker requires Node.js v18 or later.Check your current version:
node --version
Install or update Node.js:
# Install nvm
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.0/install.sh | bash

# Install Node.js
nvm install 18
nvm use 18
Git is required to clone the repository.Check if Git is installed:
git --version
Install Git:
  • macOS: brew install git (requires Homebrew)
  • Windows: Download from git-scm.com
  • Linux: sudo apt-get install git (Ubuntu/Debian) or sudo yum install git (CentOS/RHEL)
Choose one of the following package managers:npm (comes with Node.js)
npm --version
yarn (optional)
npm install -g yarn
pnpm (optional)
npm install -g pnpm

Basic Installation

1

Clone the Repository

Clone CryptoTracker from GitHub:
git clone https://github.com/sebas9526/CryptoTracker.git
cd CryptoTracker
2

Install Dependencies

Install all required npm packages:
npm install
This installs key dependencies including:
  • expo ~53.0.9 - Expo framework
  • react-native 0.79.2 - React Native core
  • expo-router ^5.0.6 - File-based routing
  • typescript ~5.8.3 - TypeScript support
  • And many more (see package.json for full list)
3

Verify Installation

Verify that everything installed correctly:
npx expo --version
You should see the Expo version number (53.0.x or similar).
The basic installation is sufficient for running the app on Expo Go or in a web browser. For native development, continue with the platform-specific setup below.

Platform-Specific Setup

iOS Development (macOS only)

1

Install Xcode

iOS development requires Xcode, which is only available on macOS.
  1. Download Xcode from the Mac App Store
  2. Install Command Line Tools:
xcode-select --install
  1. Accept the Xcode license:
sudo xcodebuild -license accept
2

Install CocoaPods

CocoaPods manages iOS dependencies:
sudo gem install cocoapods
Verify installation:
pod --version
3

Install iOS Simulator

iOS Simulator comes with Xcode. To verify it’s available:
# List available simulators
xcrun simctl list devices
4

Run on iOS

Start the app on iOS Simulator:
npm run ios

Android Development

1

Install Android Studio

Download and install Android Studio.During installation, make sure to install:
  • Android SDK
  • Android SDK Platform
  • Android Virtual Device (AVD)
2

Configure Environment Variables

Add Android SDK to your PATH:
# Add to ~/.bash_profile or ~/.zshrc
export ANDROID_HOME=$HOME/Library/Android/sdk
export PATH=$PATH:$ANDROID_HOME/emulator
export PATH=$PATH:$ANDROID_HOME/platform-tools
Verify installation:
adb --version
3

Create an Android Virtual Device

  1. Open Android Studio
  2. Go to Tools > AVD Manager
  3. Click Create Virtual Device
  4. Select a device (e.g., Pixel 5)
  5. Download a system image (e.g., API 33)
  6. Finish the setup
Or create via command line:
# List available system images
sdkmanager --list

# Create AVD
avdmanager create avd -n Pixel_5_API_33 -k "system-images;android-33;google_apis;x86_64"
4

Run on Android

Start the app on Android Emulator:
npm run android
Make sure an emulator is running or a physical device is connected via USB with USB debugging enabled.

Web Development

No additional setup required! Just run:
npm run web
The app will open in your default browser at http://localhost:19006.
Some React Native features may not work on web. The app is primarily designed for mobile platforms.

Development Tools

For the best development experience, install these VS Code extensions:
  • ES7+ React/Redux/React-Native snippets - Code snippets
  • Prettier - Code formatter
  • ESLint - Code linting
  • React Native Tools - Debugging and IntelliSense
  • TypeScript - TypeScript support

Running Tests

CryptoTracker uses Jest for testing:
npm test
Run tests in watch mode:
npm test -- --watch
Example test from the codebase (__tests__/CryptoCard.test.tsx):
import { render } from '@testing-library/react-native';
import CryptoCard from '../src/components/CryptoCard';

const mockCrypto = {
  id: '90',
  name: 'Bitcoin',
  symbol: 'BTC',
  rank: 1,
  price_usd: '50000.00',
  percent_change_24h: '2.5'
};

test('renders crypto card correctly', () => {
  const { getByText } = render(<CryptoCard crypto={mockCrypto} />);
  expect(getByText('Bitcoin')).toBeTruthy();
  expect(getByText('(BTC)')).toBeTruthy();
});

Project Configuration

TypeScript Configuration

The project uses TypeScript with strict mode enabled. See tsconfig.json:
{
  "compilerOptions": {
    "strict": true,
    "esModuleInterop": true,
    "jsx": "react-native",
    "moduleResolution": "node"
  },
  "extends": "expo/tsconfig.base"
}

Expo Configuration

Key configurations in app.json:
{
  "expo": {
    "name": "CryptoTracker",
    "slug": "CryptoTracker",
    "version": "1.0.0",
    "orientation": "portrait",
    "scheme": "cryptotracker",
    "newArchEnabled": true,
    "plugins": ["expo-router"],
    "experiments": {
      "typedRoutes": true
    }
  }
}
The app uses Expo’s new architecture (newArchEnabled: true) for improved performance.

Troubleshooting

Clear the Metro bundler cache:
npx expo start -c
Or manually clear caches:
rm -rf node_modules
rm -rf .expo
npm install
Clean iOS build:
cd ios
pod deintegrate
pod install
cd ..
npx expo run:ios
Check if virtualization is enabled in BIOS/UEFI:
# Check on Linux
egrep -c '(vmx|svm)' /proc/cpuinfo
# Result > 0 means virtualization is enabled
Try starting the emulator manually:
emulator -avd Pixel_5_API_33
Ensure TypeScript dependencies are installed:
npm install --save-dev typescript @types/react @types/react-native
Restart the TypeScript server in VS Code:
  • Press Cmd+Shift+P (Mac) or Ctrl+Shift+P (Windows/Linux)
  • Type “TypeScript: Restart TS Server”

Next Steps

Quick Start

Start building with CryptoTracker

Architecture

Learn about the app’s architecture

Components

Explore reusable components

API Reference

Understand the API integration