Skip to content

kristijan-pajtasev/object-to-map-converter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Object to Map converter

Description

A simple converter that deep converts your JavaScript Object into Map. That means that if any property anywhere in your object is also an object, it will be also converted into map.

Reasons why using Map is better than using Objects can be found in this Medium post.

Usage

const convertToMap = require("convert-to-map");
const val = {...}
const asMap = convertToMap(val);

Note:

If you pass non-object value, function throws an error.

About

Converter from JavaScript Object into JavaScript Map

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published