# ngx-calculator

> ## Overview

Latest version **1.0.8** (published 2018-08-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install ngx-calculator
pnpm add ngx-calculator
yarn add ngx-calculator
bun add ngx-calculator
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.8 |
| Published | 2018-08-15 |
| First published | 2018-01-24 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 14 |
| Unpacked size | 106.3 KB |
| Known vulnerabilities | 0 (+21 in 3 direct dependencies) |
| Install scripts | no |
| Maintainers | lucashsilva |

## Links

- npm: https://www.npmjs.com/package/ngx-calculator
- npm.io page: https://npm.io/package/ngx-calculator

## Dependencies (14)

- [rxjs](https://npm.io/package/rxjs.md) ^6.2.2
- [tslib](https://npm.io/package/tslib.md) ^1.9.0
- [core-js](https://npm.io/package/core-js.md) ^2.4.1
- [zone.js](https://npm.io/package/zone.js.md) ^0.8.26
- [rxjs-compat](https://npm.io/package/rxjs-compat.md) ^6.0.0-rc.0
- [@angular/core](https://npm.io/package/@angular/core.md) ^6.1.2
- [@angular/http](https://npm.io/package/@angular/http.md) ^6.1.2
- [@angular/forms](https://npm.io/package/@angular/forms.md) ^6.1.2
- [@angular/common](https://npm.io/package/@angular/common.md) ^6.1.2
- [@angular/router](https://npm.io/package/@angular/router.md) ^6.1.2
- [@angular/compiler](https://npm.io/package/@angular/compiler.md) ^6.1.2
- [@angular/animations](https://npm.io/package/@angular/animations.md) ^6.1.2
- [@angular/platform-browser](https://npm.io/package/@angular/platform-browser.md) ^6.1.2
- [@angular/platform-browser-dynamic](https://npm.io/package/@angular/platform-browser-dynamic.md) ^6.1.2

## Recent versions

- 1.0.8 (latest) — 2018-08-15
- 1.0.7 — 2018-08-15
- 1.0.6 — 2018-08-15
- 1.0.5 — 2018-08-15
- 1.0.4 — 2018-08-15
- 1.0.3 — 2018-08-15
- 1.0.2 — 2018-01-25
- 1.0.1 — 2018-01-25
- 1.0.0 — 2018-01-25
- 0.0.1 — 2018-01-24
- 0.0.0 — 2018-01-24

## README

# NgxCalculator - A simple calculator for Angular projects

## Overview

The calculator uses Javascript's eval() to evaluate math expressions, generating a number value as result, which can be binded using ngModel in your application for many purposes. 

You can try the calculator online at [`http://lucashsilva.github.io/ngx-calculator/`](http://lucashsilva.github.io/ngx-calculator/) or clone the repo and run the development server.

Feel free to contribute opening a pull request :) 

#### Screenshot
![enter image description here](http://i68.tinypic.com/24edq90.png)

## Installing and using
1. Install the package from npm via command line:

```
npm install --save ngx-calculator
```

2. Add `NgxCalculatorModule` as an import of your app module: 

```
import { NgxCalculatorModule } from './ngx-calculator/ngx-calculator.module';

@NgModule({
  ...
  imports: [
    NgxCalculatorModule
  ],
  ...
})
```

3. Use the component in your HTML template:

```
<ngx-calculator [(ngModel)]="value"></ngx-calculator>
```

Notice that the binding is optional and that the bind value will only change when `=` is pressed.

## Development server

Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.

<!-- ## Code scaffolding

Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.

## Build

Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `-prod` flag for a production build.

## Running unit tests

Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).

## Running end-to-end tests

Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).

## Further help

To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI README](https://github.com/angular/angular-cli/blob/master/README.md). -->

---
_Source: https://npm.io/package/ngx-calculator · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
