Writing the wsc-ng-ledger Angular component

I created wsc-ng-ledger as an Angular component to display an accounting ledger in table format.  I intend to use this in a web-app I am about to re-write that allows older Americans or their loved ones and care-givers to calculate how long they can afford to stay in various assisted living facilities.  They will use instances of this ledger in the page to itemize the move-in and monthly fee schedules of facilities they are considering.

Given an array of [ { desc: 'Item 1', amount: '100' }, ... ] the wsc-ledger directive displays an accounting ledger of items and their corresponding amounts as currency. Item descriptions and amounts are editable.


I designed wsc-ledger to bare-bones with as few dependencies and assumptions as possible.
For example, it does not depend on Bootstrap for styling. It leaves it up to the developer to display and update the total if required and to provide a button to add new items.

I am still deciding whether to provide little "delete" buttons next to each row, or remove a row when both its description and amount are blank and zero, respectively.

I created wsc-ng-ledger from the Yeoman generator generator-angular-package.  This generator uses Gulp, which has been gaining support and seems to be the way new projects are going due to it's speed and scalability, but it leaves out several key components I had to add.

Comments

Popular Posts