What is difference between Lightsail and EC2?

Testing¹ reveals that Lightsail instances in fact are EC2 instances, from the t2 class of burstable instances. EC2, of course, has many more instance families and classes other than the t2, almost all of which are more “powerful” (or better equipped for certain tasks) than these, but also much more expensive. But for meaningful comparisons, the 512 MiB … Read more

How can I merge properties of two JavaScript objects dynamically?

ECMAScript 2018 Standard Method You would use object spread: merged is now the union of obj1 and obj2. Properties in obj2 will overwrite those in obj1. Here is also the MDN documentation for this syntax. If you’re using babel you’ll need the babel-plugin-transform-object-rest-spread plugin for it to work. ECMAScript 2015 (ES6) Standard Method Method for ES5 and Earlier Note that this will simply add all attributes of obj2 to obj1 which … Read more