Skip to content

Commit

Permalink
Fix rendering of docs
Browse files Browse the repository at this point in the history
  • Loading branch information
aswinkarthik committed Oct 13, 2019
1 parent 479e99e commit 60c66ab
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ func main() {

### Reduce

Reduce can accept a reducer and apply the reducer on each element of the input slice while providing an accumulator to save the reduce output
Reduce can accept a reducer and apply the reducer on each element of the input slice while providing an accumulator to save the reduce output.
For more [docs](https://godoc.org/github.com/thecasualcoder/godash#Reduce).

```go
Expand Down
7 changes: 4 additions & 3 deletions map.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,10 @@ import (
// Currently, input and output for type slice is supported.
//
// Validations:
// 1. Mapper function should take in one argument and return one argument
// 2. Mapper function's argument should be of the same type of each element of input slice.
// 3. Mapper function's output should be of the same type of each element of output slice.
//
// 1. Mapper function should take in one argument and return one argument
// 2. Mapper function's argument should be of the same type of each element of input slice.
// 3. Mapper function's output should be of the same type of each element of output slice.
//
// Validation failures are returned as error by the godash.Map to the caller.
func Map(in, out, mapperFn interface{}) error {
Expand Down
4 changes: 2 additions & 2 deletions reduce.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ import (
// Reduce does the following validations:
//
// 1. Reducer function should accept exactly 2 arguments and return 1 argument
// 2. Reducer function's second argument should be the same type as input slice's element type
// 3. Reducer function's return type should be the same as that of the accumulator
// 2. Reducer function's second argument should be the same type as input slice's element type
// 3. Reducer function's return type should be the same as that of the accumulator
//
// Validation errors are returned to the caller.
func Reduce(in, out, reduceFn interface{}) error {
Expand Down

0 comments on commit 60c66ab

Please sign in to comment.