Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit ca92ac8

Browse files
initial documentation setup
1 parent 12bad13 commit ca92ac8

File tree

5 files changed

+38
-3
lines changed

5 files changed

+38
-3
lines changed

‎DOCUMENTATION.md‎

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# Variadic.js
2+
3+
<!-- Generated by documentation.js. Update this documentation by updating the source code. -->
4+
5+
### Table of Contents
6+
7+
- [variadic](#variadic)
8+
- [isEmpty](#isempty)
9+
10+
## variadic
11+
12+
### isEmpty
13+
14+
This function evaluates if all the parameters are empty
15+
16+
**Parameters**
17+
18+
- `params` **...any** One or more parameters.
19+
20+
**Meta**
21+
22+
- **author**: jhowardjr

‎README.md‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,10 @@ variadic.isEmpty([0, 2, 3], {}, 0); // false
4040
variadic.isEven(2, 4, 6); // error
4141
```
4242

43+
## Documenation
44+
45+
See [DOCUMENTATION.md](DOCUMENTATION.md)
46+
4347
## Running the tests
4448

4549
```

‎index.js‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
'use strict';
22

3-
// REGISTER ALL MODULES
3+
/**
4+
* @module variadic
5+
*/
46
module.exports = Object.assign(
57
{},
68
require('./lib/isEmpty.js'),

‎lib/isEmpty.js‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
'use strict';
22

3+
/**
4+
* This function evaluates if all the parameters are empty
5+
* @memberof variadic
6+
* @author jhowardjr
7+
* @param {...*} params - One or more parameters.
8+
*/
39
exports.isEmpty = (...params) => {
410
const invalid = params.some((param) => {
511
switch (typeof param) {

‎package.json‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
"lint": "eslint index.js lib/**/*.js spec/**/*.js",
99
"fix": "eslint index.js lib/**/*.js spec/**/*.js --fix",
1010
"coveralls": "nyc jasmine && nyc report --reporter=text-lcov | coveralls",
11-
"build": "BABEL_ENV=production babel index.js -d dist && BABEL_ENV=production babel lib/ -d dist/lib"
11+
"build": "BABEL_ENV=production babel index.js -d dist && BABEL_ENV=production babel lib/ -d dist/lib",
12+
"docs": "documentation readme --readme-file DOCUMENTATION.md -s Variadic.js index.js lib/**"
1213
},
1314
"repository": {
1415
"type": "git",
@@ -38,4 +39,4 @@
3839
"nyc": "^11.4.1"
3940
},
4041
"dependencies": {}
41-
}
42+
}

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /