Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

some examples

  • Loading branch information...
commit 048920ca4865c8ce99e4b731213a88c527c9e0f7 1 parent 3eadeac
James Halliday authored
Showing with 27 additions and 0 deletions.
  1. +12 −0 example/colors.js
  2. +15 −0 example/comma_first.js
12 example/colors.js
View
@@ -0,0 +1,12 @@
+var diff = require('../')({ indent : 2, comma : 'first' });
+
+function qqq () {}
+
+diff(
+ { yy : 6, zz : 5, a : [1,2,3], fn : qqq },
+ {
+ a : [ 1, 2, 3, [4], "z", /beep/, new Buffer(3) ],
+ fn : 8,
+ b : [5,6,7]
+ }
+).pipe(process.stdout, { end : false });
15 example/comma_first.js
View
@@ -0,0 +1,15 @@
+var diff = require('../')({
+ indent : 2,
+ comma : 'first',
+});
+
+function qqq () {}
+
+diff(
+ { yy : 6, zz : 5, a : [1,2,3], fn : qqq },
+ {
+ a : [ 1, 2, 3, [4], "z", /beep/, new Buffer(3) ],
+ fn : 8,
+ b : [5,6,7]
+ }
+).pipe(process.stdout, { end : false });
Please sign in to comment.
Something went wrong with that request. Please try again.