react-children-utilities
Advanced tools
Comparing version 2.0.0-beta.0 to 2.0.0-beta.1
@@ -10,8 +10,4 @@ { | ||
], | ||
"parserOptions": { | ||
"project": "./tsconfig.all.json" | ||
}, | ||
"env": { | ||
"browser": true | ||
}, | ||
"parserOptions": { "project": "./tsconfig.all.json" }, | ||
"env": { "browser": true }, | ||
"rules": { | ||
@@ -18,0 +14,0 @@ "jest/no-hooks": "off", |
{"/Users/fernandopasik/Sites/react-children-utilities/src/react-children-utilities.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/react-children-utilities.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":33}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":7}},"2":{"start":{"line":14,"column":2},"end":{"line":3,"column":42}},"3":{"start":{"line":4,"column":0},"end":{"line":4,"column":7}},"4":{"start":{"line":15,"column":2},"end":{"line":4,"column":38}},"5":{"start":{"line":5,"column":0},"end":{"line":5,"column":7}},"6":{"start":{"line":16,"column":2},"end":{"line":5,"column":44}},"7":{"start":{"line":6,"column":0},"end":{"line":6,"column":7}},"8":{"start":{"line":17,"column":2},"end":{"line":6,"column":36}},"9":{"start":{"line":7,"column":0},"end":{"line":7,"column":7}},"10":{"start":{"line":18,"column":2},"end":{"line":7,"column":34}},"11":{"start":{"line":8,"column":0},"end":{"line":8,"column":7}},"12":{"start":{"line":19,"column":2},"end":{"line":8,"column":44}},"13":{"start":{"line":9,"column":0},"end":{"line":9,"column":7}},"14":{"start":{"line":20,"column":2},"end":{"line":9,"column":44}},"15":{"start":{"line":10,"column":0},"end":{"line":10,"column":7}},"16":{"start":{"line":21,"column":2},"end":{"line":10,"column":58}},"17":{"start":{"line":11,"column":0},"end":{"line":11,"column":7}},"18":{"start":{"line":22,"column":2},"end":{"line":11,"column":38}},"19":{"start":{"line":25,"column":0},"end":{"line":35,"column":null}}},"fnMap":{},"branchMap":{},"s":{"0":1,"1":1,"2":1,"3":1,"4":1,"5":1,"6":1,"7":1,"8":1,"9":1,"10":1,"11":1,"12":1,"13":1,"14":1,"15":1,"16":1,"17":1,"18":1,"19":1},"f":{},"b":{}} | ||
,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepFilter.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepFilter.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":72}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":54}},"2":{"start":{"line":8,"column":19},"end":{"line":21,"column":1}},"3":{"start":{"line":9,"column":2},"end":{"line":20,"column":7}},"4":{"start":{"line":12,"column":6},"end":{"line":18,"column":null}},"5":{"start":{"line":14,"column":8},"end":{"line":17,"column":11}},"6":{"start":{"line":19,"column":6},"end":{"line":19,"column":19}},"7":{"start":{"line":23,"column":0},"end":{"line":23,"column":26}}},"fnMap":{"0":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":19},"end":{"line":8,"column":20}},"loc":{"start":{"line":8,"column":86},"end":{"line":21,"column":1}}},"1":{"name":"(anonymous_2)","decl":{"start":{"line":11,"column":9},"end":{"line":11,"column":10}},"loc":{"start":{"line":11,"column":19},"end":{"line":20,"column":5}}}},"branchMap":{"0":{"loc":{"start":{"line":12,"column":6},"end":{"line":18,"column":null}},"type":"if","locations":[{"start":{"line":12,"column":6},"end":{"line":18,"column":null}},{"start":{"line":12,"column":6},"end":{"line":18,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":8,"4":13,"5":4,"6":9,"7":2},"f":{"0":8,"1":13},"b":{"0":[4,9]}} | ||
,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepFind.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepFind.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":58}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":54}},"2":{"start":{"line":8,"column":17},"end":{"line":23,"column":1}},"3":{"start":{"line":10,"column":2},"end":{"line":21,"column":5}},"4":{"start":{"line":11,"column":4},"end":{"line":15,"column":null}},"5":{"start":{"line":13,"column":6},"end":{"line":13,"column":75}},"6":{"start":{"line":14,"column":6},"end":{"line":14,"column":42}},"7":{"start":{"line":16,"column":4},"end":{"line":19,"column":null}},"8":{"start":{"line":17,"column":6},"end":{"line":17,"column":20}},"9":{"start":{"line":18,"column":6},"end":{"line":18,"column":18}},"10":{"start":{"line":20,"column":4},"end":{"line":20,"column":17}},"11":{"start":{"line":22,"column":2},"end":{"line":22,"column":15}},"12":{"start":{"line":25,"column":0},"end":{"line":25,"column":24}}},"fnMap":{"0":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":17},"end":{"line":8,"column":18}},"loc":{"start":{"line":8,"column":90},"end":{"line":23,"column":1}}},"1":{"name":"(anonymous_2)","decl":{"start":{"line":10,"column":34},"end":{"line":10,"column":35}},"loc":{"start":{"line":10,"column":44},"end":{"line":21,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":11,"column":4},"end":{"line":15,"column":null}},"type":"if","locations":[{"start":{"line":11,"column":4},"end":{"line":15,"column":null}},{"start":{"line":11,"column":4},"end":{"line":15,"column":null}}]},"1":{"loc":{"start":{"line":16,"column":4},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":16,"column":4},"end":{"line":19,"column":null}},{"start":{"line":16,"column":4},"end":{"line":19,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":4,"4":7,"5":1,"6":1,"7":6,"8":2,"9":2,"10":4,"11":4,"12":2},"f":{"0":4,"1":7},"b":{"0":[1,6],"1":[2,4]}} | ||
,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepForEach.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepForEach.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":58}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":54}},"2":{"start":{"line":8,"column":20},"end":{"line":16,"column":1}},"3":{"start":{"line":9,"column":2},"end":{"line":15,"column":5}},"4":{"start":{"line":10,"column":4},"end":{"line":13,"column":null}},"5":{"start":{"line":12,"column":6},"end":{"line":12,"column":73}},"6":{"start":{"line":14,"column":4},"end":{"line":14,"column":25}},"7":{"start":{"line":18,"column":0},"end":{"line":18,"column":27}}},"fnMap":{"0":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":20},"end":{"line":8,"column":21}},"loc":{"start":{"line":8,"column":82},"end":{"line":16,"column":1}}},"1":{"name":"(anonymous_2)","decl":{"start":{"line":9,"column":29},"end":{"line":9,"column":30}},"loc":{"start":{"line":9,"column":39},"end":{"line":15,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":4},"end":{"line":13,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":4},"end":{"line":13,"column":null}},{"start":{"line":10,"column":4},"end":{"line":13,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":6,"4":11,"5":3,"6":11,"7":2},"f":{"0":6,"1":11},"b":{"0":[3,8]}} | ||
,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepMap.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepMap.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":72}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":54}},"2":{"start":{"line":8,"column":16},"end":{"line":21,"column":1}},"3":{"start":{"line":9,"column":2},"end":{"line":20,"column":5}},"4":{"start":{"line":10,"column":4},"end":{"line":18,"column":null}},"5":{"start":{"line":12,"column":6},"end":{"line":17,"column":8}},"6":{"start":{"line":19,"column":4},"end":{"line":19,"column":28}},"7":{"start":{"line":23,"column":0},"end":{"line":23,"column":23}}},"fnMap":{"0":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":16},"end":{"line":8,"column":17}},"loc":{"start":{"line":8,"column":77},"end":{"line":21,"column":1}}},"1":{"name":"(anonymous_2)","decl":{"start":{"line":9,"column":32},"end":{"line":9,"column":33}},"loc":{"start":{"line":9,"column":42},"end":{"line":20,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":4},"end":{"line":18,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":4},"end":{"line":18,"column":null}},{"start":{"line":10,"column":4},"end":{"line":18,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":6,"4":10,"5":3,"6":7,"7":2},"f":{"0":6,"1":10},"b":{"0":[3,7]}} | ||
,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepFilter.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepFilter.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":72}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":54}},"2":{"start":{"line":8,"column":19},"end":{"line":21,"column":1}},"3":{"start":{"line":9,"column":2},"end":{"line":20,"column":7}},"4":{"start":{"line":12,"column":6},"end":{"line":18,"column":null}},"5":{"start":{"line":14,"column":8},"end":{"line":17,"column":11}},"6":{"start":{"line":19,"column":6},"end":{"line":19,"column":19}},"7":{"start":{"line":23,"column":0},"end":{"line":23,"column":26}}},"fnMap":{"0":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":19},"end":{"line":8,"column":20}},"loc":{"start":{"line":8,"column":86},"end":{"line":21,"column":1}}},"1":{"name":"(anonymous_2)","decl":{"start":{"line":11,"column":9},"end":{"line":11,"column":10}},"loc":{"start":{"line":11,"column":30},"end":{"line":20,"column":5}}}},"branchMap":{"0":{"loc":{"start":{"line":12,"column":6},"end":{"line":18,"column":null}},"type":"if","locations":[{"start":{"line":12,"column":6},"end":{"line":18,"column":null}},{"start":{"line":12,"column":6},"end":{"line":18,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":8,"4":13,"5":4,"6":9,"7":2},"f":{"0":8,"1":13},"b":{"0":[4,9]}} | ||
,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepFind.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepFind.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":58}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":54}},"2":{"start":{"line":8,"column":17},"end":{"line":23,"column":1}},"3":{"start":{"line":10,"column":2},"end":{"line":21,"column":5}},"4":{"start":{"line":11,"column":4},"end":{"line":15,"column":null}},"5":{"start":{"line":13,"column":6},"end":{"line":13,"column":75}},"6":{"start":{"line":14,"column":6},"end":{"line":14,"column":42}},"7":{"start":{"line":16,"column":4},"end":{"line":19,"column":null}},"8":{"start":{"line":17,"column":6},"end":{"line":17,"column":20}},"9":{"start":{"line":18,"column":6},"end":{"line":18,"column":18}},"10":{"start":{"line":20,"column":4},"end":{"line":20,"column":17}},"11":{"start":{"line":22,"column":2},"end":{"line":22,"column":15}},"12":{"start":{"line":25,"column":0},"end":{"line":25,"column":24}}},"fnMap":{"0":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":17},"end":{"line":8,"column":18}},"loc":{"start":{"line":8,"column":90},"end":{"line":23,"column":1}}},"1":{"name":"(anonymous_2)","decl":{"start":{"line":10,"column":34},"end":{"line":10,"column":35}},"loc":{"start":{"line":10,"column":55},"end":{"line":21,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":11,"column":4},"end":{"line":15,"column":null}},"type":"if","locations":[{"start":{"line":11,"column":4},"end":{"line":15,"column":null}},{"start":{"line":11,"column":4},"end":{"line":15,"column":null}}]},"1":{"loc":{"start":{"line":16,"column":4},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":16,"column":4},"end":{"line":19,"column":null}},{"start":{"line":16,"column":4},"end":{"line":19,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":4,"4":7,"5":1,"6":1,"7":6,"8":2,"9":2,"10":4,"11":4,"12":2},"f":{"0":4,"1":7},"b":{"0":[1,6],"1":[2,4]}} | ||
,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepForEach.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepForEach.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":58}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":54}},"2":{"start":{"line":8,"column":20},"end":{"line":16,"column":1}},"3":{"start":{"line":9,"column":2},"end":{"line":15,"column":5}},"4":{"start":{"line":10,"column":4},"end":{"line":13,"column":null}},"5":{"start":{"line":12,"column":6},"end":{"line":12,"column":73}},"6":{"start":{"line":14,"column":4},"end":{"line":14,"column":25}},"7":{"start":{"line":18,"column":0},"end":{"line":18,"column":27}}},"fnMap":{"0":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":20},"end":{"line":8,"column":21}},"loc":{"start":{"line":8,"column":82},"end":{"line":16,"column":1}}},"1":{"name":"(anonymous_2)","decl":{"start":{"line":9,"column":29},"end":{"line":9,"column":30}},"loc":{"start":{"line":9,"column":50},"end":{"line":15,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":4},"end":{"line":13,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":4},"end":{"line":13,"column":null}},{"start":{"line":10,"column":4},"end":{"line":13,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":6,"4":11,"5":3,"6":11,"7":2},"f":{"0":6,"1":11},"b":{"0":[3,8]}} | ||
,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepMap.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/deepMap.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":72}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":54}},"2":{"start":{"line":8,"column":16},"end":{"line":21,"column":1}},"3":{"start":{"line":9,"column":2},"end":{"line":20,"column":5}},"4":{"start":{"line":10,"column":4},"end":{"line":18,"column":null}},"5":{"start":{"line":12,"column":6},"end":{"line":17,"column":8}},"6":{"start":{"line":19,"column":4},"end":{"line":19,"column":28}},"7":{"start":{"line":23,"column":0},"end":{"line":23,"column":23}}},"fnMap":{"0":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":16},"end":{"line":8,"column":17}},"loc":{"start":{"line":8,"column":77},"end":{"line":21,"column":1}}},"1":{"name":"(anonymous_2)","decl":{"start":{"line":9,"column":32},"end":{"line":9,"column":33}},"loc":{"start":{"line":9,"column":53},"end":{"line":20,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":4},"end":{"line":18,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":4},"end":{"line":18,"column":null}},{"start":{"line":10,"column":4},"end":{"line":18,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":6,"4":10,"5":3,"6":7,"7":2},"f":{"0":6,"1":10},"b":{"0":[3,7]}} | ||
,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/filter.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/filter.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":44}},"1":{"start":{"line":7,"column":15},"end":{"line":9,"column":1}},"2":{"start":{"line":8,"column":2},"end":{"line":8,"column":53}},"3":{"start":{"line":11,"column":0},"end":{"line":11,"column":22}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":15},"end":{"line":7,"column":16}},"loc":{"start":{"line":7,"column":78},"end":{"line":9,"column":1}}}},"branchMap":{},"s":{"0":2,"1":2,"2":4,"3":2},"f":{"0":4},"b":{}} | ||
@@ -7,0 +7,0 @@ ,"/Users/fernandopasik/Sites/react-children-utilities/src/lib/groupByType.ts": {"path":"/Users/fernandopasik/Sites/react-children-utilities/src/lib/groupByType.ts","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":74}},"1":{"start":{"line":7,"column":20},"end":{"line":28,"column":1}},"2":{"start":{"line":12,"column":2},"end":{"line":27,"column":9}},"3":{"start":{"line":13,"column":22},"end":{"line":13,"column":73}},"4":{"start":{"line":14,"column":21},"end":{"line":14,"column":79}},"5":{"start":{"line":15,"column":16},"end":{"line":15,"column":63}},"6":{"start":{"line":17,"column":4},"end":{"line":19,"column":null}},"7":{"start":{"line":18,"column":6},"end":{"line":18,"column":20}},"8":{"start":{"line":21,"column":18},"end":{"line":21,"column":29}},"9":{"start":{"line":23,"column":4},"end":{"line":25,"column":null}},"10":{"start":{"line":30,"column":0},"end":{"line":30,"column":27}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":20},"end":{"line":7,"column":null}},"loc":{"start":{"line":11,"column":21},"end":{"line":28,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":12,"column":43},"end":{"line":12,"column":44}},"loc":{"start":{"line":12,"column":89},"end":{"line":27,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":9,"column":23},"end":{"line":9,"column":25}},"type":"default-arg","locations":[{"start":{"line":9,"column":23},"end":{"line":9,"column":25}}]},"1":{"loc":{"start":{"line":10,"column":9},"end":{"line":10,"column":15}},"type":"default-arg","locations":[{"start":{"line":10,"column":9},"end":{"line":10,"column":15}}]},"2":{"loc":{"start":{"line":13,"column":22},"end":{"line":13,"column":43}},"type":"binary-expr","locations":[{"start":{"line":13,"column":22},"end":{"line":13,"column":43}},{"start":{"line":13,"column":47},"end":{"line":13,"column":73}}]},"3":{"loc":{"start":{"line":14,"column":34},"end":{"line":14,"column":71}},"type":"cond-expr","locations":[{"start":{"line":14,"column":34},"end":{"line":14,"column":71}},{"start":{"line":14,"column":74},"end":{"line":14,"column":79}}]},"4":{"loc":{"start":{"line":15,"column":29},"end":{"line":15,"column":56}},"type":"cond-expr","locations":[{"start":{"line":15,"column":29},"end":{"line":15,"column":56}},{"start":{"line":15,"column":59},"end":{"line":15,"column":63}}]},"5":{"loc":{"start":{"line":17,"column":4},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":17,"column":4},"end":{"line":19,"column":null}},{"start":{"line":17,"column":4},"end":{"line":19,"column":null}}]},"6":{"loc":{"start":{"line":25,"column":18},"end":{"line":25,"column":23}},"type":"binary-expr","locations":[{"start":{"line":25,"column":18},"end":{"line":25,"column":23}},{"start":{"line":25,"column":27},"end":{"line":25,"column":29}}]}},"s":{"0":2,"1":2,"2":3,"3":9,"4":9,"5":9,"6":9,"7":0,"8":9,"9":9,"10":2},"f":{"0":3,"1":9},"b":{"0":[0],"1":[0],"2":[9,9],"3":[6,3],"4":[6,3],"5":[0,9],"6":[9,6]}} |
{ | ||
"name": "react-children-utilities", | ||
"version": "2.0.0-beta.0", | ||
"version": "2.0.0-beta.1", | ||
"description": "Extended utils for React.Children opaque data structure", | ||
@@ -50,7 +50,7 @@ "keywords": [ | ||
"@types/enzyme-adapter-react-16": "^1.0.5", | ||
"@types/jest": "^24.0.18", | ||
"@types/react": "^16.9.5", | ||
"@types/react-dom": "^16.9.1", | ||
"@typescript-eslint/eslint-plugin": "^2.3.3", | ||
"@typescript-eslint/parser": "^2.3.3", | ||
"@types/jest": "^24.0.19", | ||
"@types/react": "^16.9.9", | ||
"@types/react-dom": "^16.9.2", | ||
"@typescript-eslint/eslint-plugin": "^2.5.0", | ||
"@typescript-eslint/parser": "^2.5.0", | ||
"bundlesize": "^0.18.0", | ||
@@ -65,7 +65,8 @@ "codecov": "^3.6.1", | ||
"eslint-plugin-import": "^2.18.2", | ||
"eslint-plugin-jest": "^22.19.0", | ||
"eslint-plugin-jest": "^22.20.0", | ||
"eslint-plugin-jsx-a11y": "^6.2.3", | ||
"eslint-plugin-prettier": "^3.1.1", | ||
"eslint-plugin-react": "^7.16.0", | ||
"eslint-plugin-react-hooks": "^2.1.2", | ||
"flow-bin": "^0.109.0", | ||
"eslint-plugin-react-hooks": "^2.2.0", | ||
"flow-bin": "^0.110.0", | ||
"flowgen": "^1.10.0", | ||
@@ -76,10 +77,11 @@ "husky": "^3.0.9", | ||
"jest-enzyme": "^7.1.1", | ||
"jest-junit": "^8.0.0", | ||
"jest-junit": "^9.0.0", | ||
"lint-staged": "^9.4.2", | ||
"make-dir-cli": "^2.0.0", | ||
"prettier": "^1.18.2", | ||
"raf": "^3.4.1", | ||
"react": "^16.10.2", | ||
"react-dom": "^16.10.2", | ||
"react-test-renderer": "^16.10.2", | ||
"rollup": "^1.23.1", | ||
"react-dom": "^16.11.0", | ||
"react-test-renderer": "^16.11.0", | ||
"rollup": "^1.25.1", | ||
"rollup-plugin-terser": "^5.1.2", | ||
@@ -90,3 +92,3 @@ "ts-jest": "^24.1.0", | ||
"peerDependencies": { | ||
"react": "15.x.x || 16.x.x" | ||
"react": "16.x.x || 15.x.x" | ||
}, | ||
@@ -93,0 +95,0 @@ "bundlesize": [ |
@@ -21,12 +21,11 @@ # React Children Utilities | ||
[badge-deps-dev]: https://david-dm.org/fernandopasik/react-children-utilities/dev-status.svg | ||
[url-size]: https://unpkg.com/react-children-utilities 'Gzip Bundle Size' | ||
[url-ci]: https://circleci.com/gh/fernandopasik/react-children-utilities 'Build Status' | ||
[url-cov]: https://codecov.io/gh/fernandopasik/react-children-utilities 'Test Coverage Status' | ||
[url-sec]: https://snyk.io/test/github/fernandopasik/react-children-utilities?targetFile=package.json 'Known Vulnerabilities' | ||
[url-version]: https://www.npmjs.com/package/react-children-utilities 'npm version' | ||
[url-downloads]: https://www.npmjs.com/package/react-children-utilities 'npm downloads' | ||
[url-deps-peer]: https://david-dm.org/fernandopasik/react-children-utilities?type=peer 'Peer Dependency Status' | ||
[url-deps-dev]: https://david-dm.org/fernandopasik/react-children-utilities?type=dev 'Dev Dependency Status' | ||
[url-size]: https://unpkg.com/react-children-utilities "Gzip Bundle Size" | ||
[url-ci]: https://circleci.com/gh/fernandopasik/react-children-utilities "Build Status" | ||
[url-cov]: https://codecov.io/gh/fernandopasik/react-children-utilities "Test Coverage Status" | ||
[url-sec]: https://snyk.io/test/github/fernandopasik/react-children-utilities?targetFile=package.json "Known Vulnerabilities" | ||
[url-version]: https://www.npmjs.com/package/react-children-utilities "npm version" | ||
[url-downloads]: https://www.npmjs.com/package/react-children-utilities "npm downloads" | ||
[url-deps-peer]: https://david-dm.org/fernandopasik/react-children-utilities?type=peer "Peer Dependency Status" | ||
[url-deps-dev]: https://david-dm.org/fernandopasik/react-children-utilities?type=dev "Dev Dependency Status" | ||
Extended utils for React.Children opaque data structure. | ||
@@ -58,10 +57,6 @@ | ||
### Children.filter | ||
- [deepFilter(children, deepFilterFn)](/docs/deep-filter.md) | ||
- [deepMap(children, deepMapFn)](/docs/deep-map.md) | ||
- [filter(children, filterFn)](/docs/filter.md) | ||
Creates a new children array with all elements that pass the test implemented by the provided function. | ||
``` | ||
Children.filter(children, callback) | ||
``` | ||
### Children.groupByType | ||
@@ -75,10 +70,2 @@ | ||
### Children.deepMap | ||
Creates a new children array with the results of calling a provided function on every element (and its children) in the provided children. | ||
``` | ||
Children.deepMap(children, callback) | ||
``` | ||
### Children.deepForEach | ||
@@ -85,0 +72,0 @@ |
@@ -11,3 +11,3 @@ import { Children, cloneElement, ReactElement, ReactNode } from 'react'; | ||
.filter(deepFilterFn) | ||
.map((child) => { | ||
.map((child: ReactNode) => { | ||
if (hasComplexChildren(child)) { | ||
@@ -14,0 +14,0 @@ // Clone the child that has children and filter them too |
@@ -10,3 +10,3 @@ import { Children, ReactNode, ReactElement } from 'react'; | ||
let found; | ||
Children.toArray(children).find((child) => { | ||
Children.toArray(children).find((child: ReactNode) => { | ||
if (hasComplexChildren(child)) { | ||
@@ -13,0 +13,0 @@ // Find inside the child that has children |
@@ -9,3 +9,3 @@ import { Children, ReactElement, ReactNode } from 'react'; | ||
const deepForEach = (children: ReactNode, deepForEachFn: ForEachFunction): void => { | ||
Children.forEach(children, (child) => { | ||
Children.forEach(children, (child: ReactNode) => { | ||
if (hasComplexChildren(child)) { | ||
@@ -12,0 +12,0 @@ // Each inside the child that has children |
@@ -9,3 +9,3 @@ import { Children, cloneElement, ReactElement, ReactNode } from 'react'; | ||
const deepMap = (children: ReactNode, deepMapFn: MapFunction): ReactNode[] => { | ||
return Children.map(children, (child) => { | ||
return Children.map(children, (child: ReactNode) => { | ||
if (hasComplexChildren(child)) { | ||
@@ -12,0 +12,0 @@ // Clone the child that has children and map them too |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
604419
138
2
41
1688
95