https://github.com/alanbsmith/sum-arr
an example library built with TypeScript and Rollup
https://github.com/alanbsmith/sum-arr
Last synced: 6 months ago
JSON representation
an example library built with TypeScript and Rollup
- Host: GitHub
- URL: https://github.com/alanbsmith/sum-arr
- Owner: alanbsmith
- License: mit
- Created: 2019-09-05T20:45:42.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2023-01-04T09:05:31.000Z (over 3 years ago)
- Last Synced: 2025-02-02T19:28:45.992Z (over 1 year ago)
- Language: JavaScript
- Homepage:
- Size: 331 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 12
-
Metadata Files:
- Readme: README.md
- Contributing: .github/CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# Sum Arr
_an example library built with TypeScript_
## Up & Running
```sh
npm install
```
## Local Development
To use this library locally, you'll first need to link the module:
```sh
npm link
```
Then tell TypeScript to watch for changes and rebuild
```sh
npm run build:watch
```
In your project directory, link this library:
```sh
npm link sum-arr
```
And import it into your code:
```js
const { sumArr } = require('sum-arr');
const arr = [1, 2, 3, 4, 5];
return sumArr(arr);
```
Remember to clean up when you're done:
```sh
npm unlink sum-arr
```
## Running Linters & Tests
### Linters
```sh
npm run lint
```
### Tests
```sh
npm test
```
### Test Coverage
```sh
npm run test:coverage:report
```
## License
[MIT](LICENSE)