contentful-resolve-response 1.3.2 → 1.3.3

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.
package/dist/cjs/index.js CHANGED
@@ -86,6 +86,7 @@ var walkMutate = function walkMutate(input, predicate, mutator, removeUnresolved
86
86
 
87
87
  if (input && typeof input === 'object') {
88
88
  for (var key in input) {
89
+ // eslint-disable-next-line no-prototype-builtins
89
90
  if (input.hasOwnProperty(key)) {
90
91
  input[key] = walkMutate(input[key], predicate, mutator, removeUnresolved);
91
92
  }
@@ -124,7 +125,7 @@ var makeEntryObject = function makeEntryObject(item, itemEntryPoints) {
124
125
  * resolveResponse Function
125
126
  * Resolves contentful response to normalized form.
126
127
  * @param {Object} response Contentful response
127
- * @param {Object} options
128
+ * @param {{removeUnresolved: Boolean, itemEntryPoints: Array<String>}|{}} options
128
129
  * @param {Boolean} options.removeUnresolved - Remove unresolved links default:false
129
130
  * @param {Array<String>} options.itemEntryPoints - Resolve links only in those item properties
130
131
  * @return {Object}
package/dist/esm/index.js CHANGED
@@ -78,6 +78,7 @@ var walkMutate = function walkMutate(input, predicate, mutator, removeUnresolved
78
78
 
79
79
  if (input && (typeof input === 'undefined' ? 'undefined' : _typeof(input)) === 'object') {
80
80
  for (var key in input) {
81
+ // eslint-disable-next-line no-prototype-builtins
81
82
  if (input.hasOwnProperty(key)) {
82
83
  input[key] = walkMutate(input[key], predicate, mutator, removeUnresolved);
83
84
  }
@@ -116,7 +117,7 @@ var makeEntryObject = function makeEntryObject(item, itemEntryPoints) {
116
117
  * resolveResponse Function
117
118
  * Resolves contentful response to normalized form.
118
119
  * @param {Object} response Contentful response
119
- * @param {Object} options
120
+ * @param {{removeUnresolved: Boolean, itemEntryPoints: Array<String>}|{}} options
120
121
  * @param {Boolean} options.removeUnresolved - Remove unresolved links default:false
121
122
  * @param {Array<String>} options.itemEntryPoints - Resolve links only in those item properties
122
123
  * @return {Object}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "contentful-resolve-response",
3
- "version": "1.3.2",
3
+ "version": "1.3.3",
4
4
  "description": "",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "module": "./dist/esm/index.js",
@@ -25,33 +25,33 @@
25
25
  "node": ">=4.7.2"
26
26
  },
27
27
  "dependencies": {
28
- "fast-copy": "^2.1.0"
28
+ "fast-copy": "^2.1.1"
29
29
  },
30
30
  "devDependencies": {
31
- "@commitlint/cli": "^9.0.1",
32
- "@commitlint/config-conventional": "^9.0.1",
33
- "@contentful/eslint-config-backend": "^7.0.0",
34
- "@semantic-release/changelog": "^5.0.1",
35
- "@semantic-release/git": "^9.0.0",
31
+ "@commitlint/cli": "^16.2.1",
32
+ "@commitlint/config-conventional": "^16.2.1",
33
+ "@contentful/eslint-config-backend": "^10.0.0",
34
+ "@semantic-release/changelog": "^6.0.1",
35
+ "@semantic-release/git": "^10.0.1",
36
36
  "@timbeyer/commitlint-circle": "^3.0.0",
37
37
  "babel-cli": "^6.26.0",
38
38
  "babel-plugin-add-module-exports": "^1.0.2",
39
39
  "babel-preset-env": "^1.7.0",
40
40
  "babel-register": "^6.26.0",
41
- "chai": "^4.2.0",
41
+ "chai": "^4.3.6",
42
42
  "dirty-chai": "^2.0.1",
43
- "eslint": "^6.4.0",
44
- "eslint-config-prettier": "^6.11.0",
45
- "eslint-plugin-import": "^2.18.2",
46
- "eslint-plugin-mocha": "^6.1.1",
47
- "eslint-plugin-node": "^10.0.0",
48
- "eslint-plugin-prettier": "^3.1.4",
49
- "eslint-plugin-promise": "^4.2.1",
50
- "eslint-plugin-standard": "^4.0.1",
43
+ "eslint": "^8.9.0",
44
+ "eslint-config-prettier": "^8.4.0",
45
+ "eslint-plugin-import": "^2.25.4",
46
+ "eslint-plugin-mocha": "^10.0.3",
47
+ "eslint-plugin-node": "^11.1.0",
48
+ "eslint-plugin-prettier": "^4.0.0",
49
+ "eslint-plugin-promise": "^6.0.0",
50
+ "eslint-plugin-standard": "^5.0.0",
51
51
  "husky": "^3.0.5",
52
52
  "mocha": "^6.2.0",
53
- "prettier": "^2.0.5",
54
- "semantic-release": "^17.1.1"
53
+ "prettier": "^2.5.1",
54
+ "semantic-release": "^19.0.2"
55
55
  },
56
56
  "files": [
57
57
  "dist"
package/CHANGELOG.md DELETED
@@ -1,107 +0,0 @@
1
- ## [1.3.2](https://github.com/contentful/contentful-resolve-response/compare/v1.3.1...v1.3.2) (2022-02-24)
2
-
3
- ## [1.3.1](https://github.com/contentful/contentful-resolve-response/compare/v1.3.0...v1.3.1) (2022-02-24)
4
-
5
- # [1.3.0](https://github.com/contentful/contentful-resolve-response/compare/v1.2.2...v1.3.0) (2020-11-25)
6
-
7
-
8
- ### Features
9
-
10
- * remove lodash and replace cloneDeep with fast-copy ([b6bffed](https://github.com/contentful/contentful-resolve-response/commit/b6bffed343eebf4913d397a4e157787028929692))
11
-
12
- ## [1.2.2](https://github.com/contentful/contentful-resolve-response/compare/v1.2.1...v1.2.2) (2020-07-03)
13
-
14
-
15
- ### Bug Fixes
16
-
17
- * bump to 1.2.2 for semantic-release ([b835e90](https://github.com/contentful/contentful-resolve-response/commit/b835e90b9a800712f43576e141500508cefdfffd))
18
-
19
- ## [1.2.1](https://github.com/contentful/contentful-resolve-response/compare/v1.2.0...v1.2.1) (2020-07-03)
20
-
21
-
22
- ### Bug Fixes
23
-
24
- * bump to 1.2.1 for semantic-release ([0cf7de5](https://github.com/contentful/contentful-resolve-response/commit/0cf7de51032933f734dd72011f5b518f5583b6da))
25
-
26
- # [1.2.0](https://github.com/contentful/contentful-resolve-response/compare/v1.1.2...v1.2.0) (2020-07-03)
27
-
28
-
29
- ### Bug Fixes
30
-
31
- * **get-link:** better performance on large input ([9b1bab0](https://github.com/contentful/contentful-resolve-response/commit/9b1bab06b2ff8d5037e66d7bdd131a51e4d82062))
32
- * Update deps ([587f04c](https://github.com/contentful/contentful-resolve-response/commit/587f04ccd36d62d0241721ee7bbcd00c4f0cfcdc))
33
- * Update Nodejs version ([d4550e0](https://github.com/contentful/contentful-resolve-response/commit/d4550e0b2941a3080b06954ac0d7eb9da4f8a6cd))
34
- * **array-fields:** proper unresolved removal while iterating array ([#19](https://github.com/contentful/contentful-resolve-response/issues/19)) ([39bf40d](https://github.com/contentful/contentful-resolve-response/commit/39bf40d7e38f5e3a0bce96491448c333d128b850))
35
- * **compatibility:** indexOf instead of includes([#18](https://github.com/contentful/contentful-resolve-response/issues/18)) ([1c3b277](https://github.com/contentful/contentful-resolve-response/commit/1c3b277c2189b966841a86da276de018618aa1ce))
36
-
37
-
38
- ### Features
39
-
40
- * bump to 1.2.0 for semantic-release ([08a5c8a](https://github.com/contentful/contentful-resolve-response/commit/08a5c8aca742e545a65f27ca32b14d17b618a76b))
41
-
42
- ## [1.1.3](https://github.com/contentful/contentful-resolve-response/compare/v1.1.2...v1.1.3) (2020-07-03)
43
-
44
-
45
- ### Bug Fixes
46
-
47
- * **get-link:** better performance on large input ([9b1bab0](https://github.com/contentful/contentful-resolve-response/commit/9b1bab06b2ff8d5037e66d7bdd131a51e4d82062))
48
- * Update deps ([587f04c](https://github.com/contentful/contentful-resolve-response/commit/587f04ccd36d62d0241721ee7bbcd00c4f0cfcdc))
49
- * Update Nodejs version ([d4550e0](https://github.com/contentful/contentful-resolve-response/commit/d4550e0b2941a3080b06954ac0d7eb9da4f8a6cd))
50
- * **array-fields:** proper unresolved removal while iterating array ([#19](https://github.com/contentful/contentful-resolve-response/issues/19)) ([39bf40d](https://github.com/contentful/contentful-resolve-response/commit/39bf40d7e38f5e3a0bce96491448c333d128b850))
51
- * **compatibility:** indexOf instead of includes([#18](https://github.com/contentful/contentful-resolve-response/issues/18)) ([1c3b277](https://github.com/contentful/contentful-resolve-response/commit/1c3b277c2189b966841a86da276de018618aa1ce))
52
-
53
- ## [1.1.3](https://github.com/contentful/contentful-resolve-response/compare/v1.1.2...v1.1.3) (2020-07-03)
54
-
55
-
56
- ### Bug Fixes
57
-
58
- * Update deps ([587f04c](https://github.com/contentful/contentful-resolve-response/commit/587f04ccd36d62d0241721ee7bbcd00c4f0cfcdc))
59
- * Update Nodejs version ([d4550e0](https://github.com/contentful/contentful-resolve-response/commit/d4550e0b2941a3080b06954ac0d7eb9da4f8a6cd))
60
- * **array-fields:** proper unresolved removal while iterating array ([#19](https://github.com/contentful/contentful-resolve-response/issues/19)) ([39bf40d](https://github.com/contentful/contentful-resolve-response/commit/39bf40d7e38f5e3a0bce96491448c333d128b850))
61
- * **compatibility:** indexOf instead of includes([#18](https://github.com/contentful/contentful-resolve-response/issues/18)) ([1c3b277](https://github.com/contentful/contentful-resolve-response/commit/1c3b277c2189b966841a86da276de018618aa1ce))
62
-
63
- # Change Log
64
- All notable changes to this project will be documented in this file.
65
-
66
- ## v1.1.4 - 2018-02-21
67
-
68
- ### Bug Fixes
69
-
70
- * **array-fields:** proper unresolved removal while iterating array ([#19](https://github.com/contentful/contentful-resolve-response/pull/19)) ([39bf40d7](https://github.com/contentful/contentful-resolve-response/commit/39bf40d7e38f5e3a0bce96491448c333d128b850))
71
-
72
- ## v1.1.3 - 2018-02-12
73
-
74
- ### Bug Fixes
75
-
76
- * **compatibility:** indexOf instead of includes([#18](https://github.com/contentful/contentful-resolve-response/pull/18)) ([1c3b277c](https://github.com/contentful/contentful-resolve-response/commit/1c3b277c2189b966841a86da276de018618aa1ce))
77
-
78
- ## v1.1.2
79
-
80
- ### Build System / Dependencies
81
-
82
- * **esm:** provide esm version for bundlers ([#16](https://github.com/contentful/contentful-resolve-response/pull/16)) ([a40cabb7](https://github.com/contentful/contentful-resolve-response/commit/a40cabb73e099347cd7a77679ba4060f20d07b65))
83
-
84
- ### Documentation Changes
85
-
86
- * **package.json:** fix urls ([70f61377](https://github.com/contentful/contentful-resolve-response/commit/70f6137787345cdb5913dd198b597e446ab16390))
87
- * **README:** add npm version badge ([724b5ef6](https://github.com/contentful/contentful-resolve-response/commit/724b5ef684fa12d3a539e23ad089da3b3a047199))
88
-
89
- ## v1.1.1
90
-
91
- ### Bug Fixes
92
-
93
- * **removeUnresolved:** remove instead of set to undefined ([#15](https://github.com/contentful/contentful-resolve-response/pull/15)) ([a58906b1](https://github.com/contentful/contentful-resolve-response/commit/a58906b1df9218cfebf9974e6969d07d87a9dc05))
94
-
95
- ## v1.1.0 - 2018-01-17
96
- ### Added
97
- - _[options]_ allow explicit item entry points
98
-
99
- ### Changed
100
- - _[pkg]_ manually set version field to 1.0.1
101
- - _[githooks]_ lint every commit, test every push (#13)
102
- - _[gitignore]_ ignore coverage and other irrelevant files
103
- - _[coverage]_ add code coverage reports
104
- - _[unit]_ circular references in multi value fields (#11)
105
-
106
- ### Fixed
107
- - _[lodash]_ require explicit to allow tree shaking (#10)