Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 10 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,16 +57,14 @@ console.log(diff(lhs, rhs));

`human-object-diff` supports a variety of options to allow you to take control over the output of your object diff.

| Option | type | Default | Description |
| ------------------------------- | ------------ | ---------------------------------- | --------------------------------------------------------------------------------------- | --------------------------------- |
| objectName | String | 'Obj' | This is the object name when presented in the path. ie... "Obj.foo" ignored if hidePath |
| is true |
| prefilter | \[String\]\ | Func | | see [prefiltering](#prefiltering) |
| dateFormat | String | 'MM/dd/yyyy hh:mm a' | dateFns format string |
| see [below](#support-for-dates) |
| ignoreArrays | Bool | false | If array differences aren't needed. Set to true and skip processing |
| templates | Object | see [templates](#custom-templates) | Completely customize the output. |
| sensitivePaths | \[String\] | | Paths that will use the sensitive field templates if they are defined |
| Option | Type | Default | Description |
| -------------- | -------- | ---------------------------------- | ----------------------------------------------------------------------------------------------- |
| objectName | String | 'Obj' | This is the object name when presented in the path. ie... "Obj.foo" ignored if hidePath is true |
| prefilter | [String] | Func | See [prefiltering](#prefiltering) |
| dateFormat | String | 'MM/dd/yyyy hh:mm a' | dateFns format string, see [below](#support-for-dates) |
| ignoreArrays | Bool | false | If array differences aren't needed, set to true and skip processing |
| templates | Object | see [templates](#custom-templates) | Completely customize the output |
| sensitivePaths | [String] | | Paths that will use the sensitive field templates if they are defined, use [] as any index |

### Custom Templates

Expand Down Expand Up @@ -203,11 +201,11 @@ diffEngine.sentences; // -> same as the output of the last diff

| Name | Website |
| ------------------ | -------------------------- |
| **Spencer Snyder** | <http://spencersnyder.io/> |
| **Spencer Snyder** | <https://spencersnyder.io/> |
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feel free to add yourself too!


## License

[MIT](LICENSE) © [Spencer Snyder](http://spencersnyder.io/)
[MIT](LICENSE) © [Spencer Snyder](https://spencersnyder.io/)

##

Expand Down