@commercetools-frontend/url-utils 27.15.0 → 27.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,14 +9,11 @@ function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e };
9
9
  var _mapInstanceProperty__default = /*#__PURE__*/_interopDefault(_mapInstanceProperty);
10
10
 
11
11
  // NOTE: This string will be replaced on build time with the package version.
12
- var version = "27.15.0";
12
+ var version = "27.16.0";
13
13
 
14
14
  const matchLeadingAndTrailingSlashes = /^\/|\/$/g;
15
15
  const trimLeadingAndTrailingSlashes = url => url.replace(matchLeadingAndTrailingSlashes, '');
16
- const joinPaths = function () {
17
- for (var _len = arguments.length, paths = new Array(_len), _key = 0; _key < _len; _key++) {
18
- paths[_key] = arguments[_key];
19
- }
16
+ const joinPaths = (...paths) => {
20
17
  const joint = _mapInstanceProperty__default["default"](paths).call(paths, path => {
21
18
  if (typeof path !== 'string') throw new Error(`Expected path "${path}" to be a "string", but got "${typeof path}"`);
22
19
  // Trim leading and trailing slash for each single path
@@ -9,14 +9,11 @@ function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e };
9
9
  var _mapInstanceProperty__default = /*#__PURE__*/_interopDefault(_mapInstanceProperty);
10
10
 
11
11
  // NOTE: This string will be replaced on build time with the package version.
12
- var version = "27.15.0";
12
+ var version = "27.16.0";
13
13
 
14
14
  const matchLeadingAndTrailingSlashes = /^\/|\/$/g;
15
15
  const trimLeadingAndTrailingSlashes = url => url.replace(matchLeadingAndTrailingSlashes, '');
16
- const joinPaths = function () {
17
- for (var _len = arguments.length, paths = new Array(_len), _key = 0; _key < _len; _key++) {
18
- paths[_key] = arguments[_key];
19
- }
16
+ const joinPaths = (...paths) => {
20
17
  const joint = _mapInstanceProperty__default["default"](paths).call(paths, path => {
21
18
  if (typeof path !== 'string') throw new Error(`Expected path "${path}" to be a "string", but got "${typeof path}"`);
22
19
  // Trim leading and trailing slash for each single path
@@ -1,14 +1,11 @@
1
1
  import _mapInstanceProperty from '@babel/runtime-corejs3/core-js-stable/instance/map';
2
2
 
3
3
  // NOTE: This string will be replaced on build time with the package version.
4
- var version = "27.15.0";
4
+ var version = "27.16.0";
5
5
 
6
6
  const matchLeadingAndTrailingSlashes = /^\/|\/$/g;
7
7
  const trimLeadingAndTrailingSlashes = url => url.replace(matchLeadingAndTrailingSlashes, '');
8
- const joinPaths = function () {
9
- for (var _len = arguments.length, paths = new Array(_len), _key = 0; _key < _len; _key++) {
10
- paths[_key] = arguments[_key];
11
- }
8
+ const joinPaths = (...paths) => {
12
9
  const joint = _mapInstanceProperty(paths).call(paths, path => {
13
10
  if (typeof path !== 'string') throw new Error(`Expected path "${path}" to be a "string", but got "${typeof path}"`);
14
11
  // Trim leading and trailing slash for each single path
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@commercetools-frontend/url-utils",
3
- "version": "27.15.0",
3
+ "version": "27.16.0",
4
4
  "description": "Utility functions to work with URLs",
5
5
  "bugs": "https://github.com/commercetools/merchant-center-application-kit/issues",
6
6
  "repository": {