https://github.com/willhackett/notepads-n-things
https://github.com/willhackett/notepads-n-things
Last synced: 9 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/willhackett/notepads-n-things
- Owner: willhackett
- Created: 2017-11-24T02:09:38.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-12-15T17:33:09.000Z (over 2 years ago)
- Last Synced: 2023-12-15T18:42:07.540Z (over 2 years ago)
- Language: JavaScript
- Size: 21.5 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Notepad 'n' Things
## Code Challenge
You work for a national chain of Notepads 'n' Things, a national chain of stationery and giftware stores. The CEO of Notepads 'n' Things is keen to know how the portfolio of stores performed in January during the 'back to school' season.
## Installation
Ensure you have the Yarn package manager.
Run:
`yarn build`
Optionally run tests:
`yarn test`
## Command Line Interface
Using the CLI and Node, Notepad 'n' Things staff can query the sales data JSON file.
Display the total sales reported by the flagship store in Chadstone:
`./query sales_data.json --centre "Chadstone"`
Display the centre which had the most sales:
`./query sales_data.json --best totalSales`
Display the total sales reported by stores in Victoria:
`./query sales_data.json --state VIC --totals`
Display the centre with the highest sales PSM:
`./query sales_data.json --best psm`