Skip to content

Lesha-spr/object-sort

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

object-sort

Returns new object with sorted keys order.

Usage

npm install object-sort
var objectSort = require('object-sort');
var obj = {b: 3, c: 5, a: 1};

objectSort(obj); // {a: 1, b: 3, c: 5}

// With reverse flag
objectSort(obj, true); // {c: 5, b: 3, a: 1}

About

Sorts object by keys

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published