JSPM

@ranalubis/xtend

4.0.3
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 5
  • Score
    100M100P100Q50962F
  • License MIT

extend like a boss

Package Exports

  • @ranalubis/xtend
  • @ranalubis/xtend/immutable.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@ranalubis/xtend) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

xtend

locked

This function is too small, just copy & paste it.

Also Object.assign(a, b) or { ...a } for shallow extension / copies.

Description

Extend like a boss

xtend is a basic utility library which allows you to extend an object by appending all of the properties from each object in a list. When there are identical properties, the right-most property takes precedence.

Examples

var extend = require("xtend");

// extend returns a new object. Does not mutate arguments
var combination = extend(
  {
    a: "a",
    b: "c",
  },
  {
    b: "b",
  }
);
// { a: "a", b: "b" }

Stability status: Locked

MIT Licensed