{"id":367,"date":"2015-04-22T23:59:25","date_gmt":"2015-04-22T14:59:25","guid":{"rendered":"http:\/\/tajibook.com\/?p=367"},"modified":"2015-04-25T15:16:05","modified_gmt":"2015-04-25T06:16:05","slug":"merge-hashes","status":"publish","type":"post","link":"https:\/\/blog.codebase.co.jp\/en\/merge-hashes","title":{"rendered":"Merge Hashes"},"content":{"rendered":"<p>Javascript doesn&#8217;t have standard function to merger hashes. We can do it like below.<\/p>\n<pre class=\"lang:js decode:true  \">var hash1 = {'us': 'USD', 'jp': 'JPY'};\r\nvar hash2 = {'cn': 'CNY'};\r\n\r\nfor (var key in hash2) {\r\n    hash1[key] = hash2[key];\r\n}<\/pre>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Javascript doesn&#8217;t have standard function to merger hashes. We can do it like below. var hash1 = {&#8216;us&#8217;:  (&hellip;) <a href=\"https:\/\/blog.codebase.co.jp\/en\/merge-hashes\">Read more<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_locale":"en_US","_original_post":"363","footnotes":""},"categories":[27],"tags":[],"class_list":["post-367","post","type-post","status-publish","format-standard","hentry","category-javascript","en-US"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/posts\/367","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/comments?post=367"}],"version-history":[{"count":3,"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/posts\/367\/revisions"}],"predecessor-version":[{"id":401,"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/posts\/367\/revisions\/401"}],"wp:attachment":[{"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/media?parent=367"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/categories?post=367"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.codebase.co.jp\/wp-json\/wp\/v2\/tags?post=367"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}