instance method Hash#toObject

View source on GitHub →

Hash#toObject() → Object

Returns a cloned, vanilla object whose properties (and property values) match the keys (and values) from the hash.

Example
var h = new Hash({ a: 'apple', b: 'banana', c: 'coconut' });
var obj = h.toObject();
obj.a;
// -> "apple"

Aliased as: Hash#toJSON, Hash#toTemplateReplacements