Skip to content

Commit

Permalink
Fix inconsistent indentation (#175)
Browse files Browse the repository at this point in the history
Fix inconsistent indentation
  • Loading branch information
TehShrike authored Oct 24, 2019
2 parents 0a890fc + da8e665 commit d1ae60f
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -209,29 +209,29 @@ It may also return undefined, in which case the default merge behaviour will be

```js
const alex = {
name: {
first: 'Alex',
last: 'Alexson'
},
pets: ['Cat', 'Parrot']
name: {
first: 'Alex',
last: 'Alexson'
},
pets: ['Cat', 'Parrot']
}

const tony = {
name: {
first: 'Tony',
last: 'Tonison'
},
pets: ['Dog']
name: {
first: 'Tony',
last: 'Tonison'
},
pets: ['Dog']
}

const mergeNames = (nameA, nameB) => `${nameA.first} and ${nameB.first}`

const options = {
customMerge: (key) => {
if (key === 'name') {
return mergeNames
}
}
customMerge: (key) => {
if (key === 'name') {
return mergeNames
}
}
}

const result = merge(alex, tony, options)
Expand Down

0 comments on commit d1ae60f

Please sign in to comment.