A modern, feature-rich calculator mobile application built with React Native and Expo. This calculator offers a sleek dark interface with smooth animations and intuitive user experience.
- Basic Arithmetic Operations: Addition, subtraction, multiplication, and division
- Advanced Functions:
- Percentage calculations
- Toggle sign (+/-)
- Decimal point support
- Smart Expression Display: Shows both the current input and the ongoing calculation
- Number Formatting: Automatic comma separation for thousands
- Error Handling: Division by zero protection
- Responsive Design: Optimized for various screen sizes
- Modern UI: Dark theme with smooth animations and visual feedback
The calculator features:
- Clean, dark-themed interface
- Large, easy-to-read display
- Color-coded buttons (operators in orange, functions in gray, numbers in dark gray)
- Expression history display above main result
- Smooth touch feedback
- Node.js (v14 or higher)
- npm or yarn
- Expo CLI
- Expo Go app (for testing on physical devices)
- Clone the repository:
git clone https://github.com/danujaadikari/Calculator.git
cd Calculator- Install dependencies:
npm install
# or
yarn install- Start the development server:
npm start
# or
expo start- Run on your device:
- Scan the QR code with Expo Go (Android) or Camera app (iOS)
- Or press
afor Android emulator - Or press
ifor iOS simulator - Or press
wto run in web browser
npm start- Start the Expo development servernpm run android- Run on Android device/emulatornpm run ios- Run on iOS simulator (macOS only)npm run web- Run in web browser
- React Native (0.74.5) - Mobile application framework
- React (18.2.0) - JavaScript library for building user interfaces
- Expo (~51.0.0) - Platform for making universal React applications
- Expo Status Bar (~1.12.1) - Status bar component
Calculator/
├── App.js # Main application component with calculator logic
├── app.json # Expo configuration
├── package.json # Project dependencies and scripts
├── babel.config.js # Babel configuration
├── README.md # Project documentation
└── LICENSE # License file
- Number Input: Tap number buttons (0-9) to input values
- Operators: Use +, −, ×, ÷ for calculations
- Equals: Press = to see the result
- Clear: Press C to reset the calculator
- Toggle Sign: Press ± to switch between positive and negative
- Percentage: Press % to convert the current value to percentage
- Decimal: Press . to add decimal point
The calculator shows your ongoing calculation at the top and the current input/result below, making it easy to track your calculations.
Large numbers are automatically formatted with commas (e.g., 1,000,000) for better readability.
You can perform multiple operations in sequence without pressing equals after each operation.
Contributions, issues, and feature requests are welcome! Feel free to check the issues page.
- Fork the project
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
Danuja Adikari
📧 Email : danujaadikari2001@gmail.com
💼 LinkedIn : linkedin.com/in/danuja-adikari