[Pkg-javascript-commits] [node-clean-yaml-object] 07/21: documentation tweaks

Bastien Roucariès rouca at moszumanska.debian.org
Thu Sep 7 09:52:17 UTC 2017


This is an automated email from the git hooks/post-receive script.

rouca pushed a commit to branch master
in repository node-clean-yaml-object.

commit 2d473ffa475e5c239cd89d0c3dc848b49ece9937
Author: James Talmage <james at talmage.io>
Date:   Fri Jan 15 22:58:25 2016 -0500

    documentation tweaks
---
 package.json | 10 ++++++++--
 readme.md    | 10 +++++-----
 2 files changed, 13 insertions(+), 7 deletions(-)

diff --git a/package.json b/package.json
index b535dcb..39b70c6 100644
--- a/package.json
+++ b/package.json
@@ -1,7 +1,7 @@
 {
   "name": "clean-yaml-object",
   "version": "0.0.1",
-  "description": "My flawless module",
+  "description": "Clean up an object prior to serialization",
   "license": "MIT",
   "repository": "jamestalmage/clean-yaml-object",
   "author": {
@@ -19,7 +19,13 @@
     "index.js"
   ],
   "keywords": [
-    ""
+    "serialize",
+    "clean",
+    "dedupe",
+    "circular",
+    "yaml",
+    "json",
+    "error"
   ],
   "dependencies": {},
   "devDependencies": {
diff --git a/readme.md b/readme.md
index 348db9d..f998bf6 100644
--- a/readme.md
+++ b/readme.md
@@ -1,8 +1,8 @@
 # clean-yaml-object [![Build Status](https://travis-ci.org/jamestalmage/clean-yaml-object.svg?branch=master)](https://travis-ci.org/jamestalmage/clean-yaml-object)
 
-> Cleans an object up for pretty printing.
+> Clean up an object prior to serialization.
 
-Replaces circular references, pretty prints Buffers, and numerous other enhancements. Primarily designed to serialize Errors for serialization to JSON/YAML.
+Replaces circular references, pretty prints Buffers, and numerous other enhancements. Primarily designed to prepare Errors for serialization to JSON/YAML.
 
 Extracted from [`node-tap`](https://github.com/tapjs/node-tap)
 
@@ -27,7 +27,7 @@ cleanYamlObject(new Error('foo'));
 
 ### cleanYamlObject(input, [filterFn])
 
-Returns a deep copy of `input`, 
+Returns a deep copy of `input` that is suitable for serialization. 
 
 #### input
 
@@ -37,9 +37,9 @@ Any object.
 
 #### filterFn
 
-Type: `function(propertyName, isRoot, source, target)`
+Type: `callback(propertyName, isRoot, source, target)`
 
-Optional filter function. Returning `true` will cause the property to be copied.
+Optional filter callback. Returning `true` will cause the property to be copied. Otherwise it will be skipped
 
 - `propertyName`: The property being copied.
 - `isRoot`: `true` only if `source` is the top level object passed to `copyYamlObject`

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-clean-yaml-object.git



More information about the Pkg-javascript-commits mailing list