Skip to content

A simple calculator in plain JavaScript. Supports term grouping and arbitrary precision calculations.

License

Notifications You must be signed in to change notification settings

tasxatzial/calculator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Calculator

A simple calculator that supports the 4 basic operations on decimal numbers and grouping of terms using parentheses.

Features

  • Dark & light theme. The selected theme is restored when the page reloads.
  • If the user has not selected a theme, the applied theme is always synchronized with the system theme.
  • Calculations are saved in history and can be reloaded.
  • History is restored when the page reloads.
  • Keyboard input is supported.
  • Arbitrary precision calculations with decimal.js.

Implementation

  • Accessible + screen reader friendly.
  • Variation of the MVC pattern (only for inputting expressions, performing calculations, and displaying the results).
  • Expressions are calculated with the Shunting yard algorithm.

Dependencies

The project is written in HTML, CSS, JavaScript.

The following dependencies will be installed via npm install:

Run locally

Install the required dependencies:

npm install

Run the development version:

npm run dev

Build the project:

npm run build

Build & serve the production version:

npm run serve

Screenshots

See screenshots.

About

A simple calculator in plain JavaScript. Supports term grouping and arbitrary precision calculations.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published