Skip to content

Commit

Permalink
feat: use typescript (#2)
Browse files Browse the repository at this point in the history
* refactor: use typescript

* refactor: test

* fix: cleanup

* feat: bump version

* fix: cleanup mocha refs

* fix: update bower config

Co-authored-by: Lu Jiang <[email protected]>
  • Loading branch information
ljiang-ti and ljiang-ti authored Jun 3, 2022
1 parent 4067a30 commit 0844e48
Show file tree
Hide file tree
Showing 12 changed files with 8,482 additions and 134 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
node_modules
bower_components
dist
8 changes: 0 additions & 8 deletions Makefile

This file was deleted.

19 changes: 13 additions & 6 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,17 @@
## Usage

```js
var couponable = require('couponable');
couponable.discountable(amountInCents, percentOff, amountOffInCents);
couponable.totalDueNow(orderItem);
couponable.totalRecurring(orderItem);
couponable.totalLineOne(orderItem);
couponable.totalLineTwo(orderItem);
import {
discountable,
totalDueNow,
totalRecurring,
totalLineOne,
totalLineTwo
} from 'couponable';

discountable(amountInCents, percentOff, amountOffInCents);
totalDueNow(orderItem);
totalRecurring(orderItem);
totalLineOne(orderItem);
totalLineTwo(orderItem);
```
Loading

0 comments on commit 0844e48

Please sign in to comment.