kitsu-core
Advanced tools
Comparing version 9.1.16 to 9.1.17
@@ -6,2 +6,14 @@ # Change Log | ||
## [9.1.17](https://github.com/wopian/kitsu/tree/master/packages/kitsu-core/compare/v9.1.16...v9.1.17) (2020-12-06) | ||
### Chores | ||
* **release:** update documentation ([89746a8](https://github.com/wopian/kitsu/tree/master/packages/kitsu-core/commit/89746a8)) | ||
## [9.1.16](https://github.com/wopian/kitsu/tree/master/packages/kitsu-core/compare/v9.1.15...v9.1.16) (2020-10-25) | ||
@@ -8,0 +20,0 @@ |
@@ -1,1 +0,1 @@ | ||
"use strict";module.exports=e=>e.replace(/[-_][a-z\u00E0-\u00F6\u00F8-\u00FE]/g,e=>e.slice(1).toUpperCase()); | ||
"use strict";module.exports=e=>e.replace(/[-_][a-z\u00E0-\u00F6\u00F8-\u00FE]/g,(e=>e.slice(1).toUpperCase())); |
@@ -1,1 +0,1 @@ | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.deattribute=function t(e){var r;if("object"==typeof e&&null!==e)if(Array.isArray(e))e.map(e=>t(e));else if((null===(r=e.attributes)||void 0===r?void 0:r.constructor)===Object){for(const t of Object.keys(e.attributes))e.attributes.attributes||(e[t]=e.attributes[t]);e.attributes.attributes?e.attributes=e.attributes.attributes:delete e.attributes}return e}; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.deattribute=function t(e){var r;if("object"==typeof e&&null!==e)if(Array.isArray(e))e.map((e=>t(e)));else if((null===(r=e.attributes)||void 0===r?void 0:r.constructor)===Object){for(const t of Object.keys(e.attributes))e.attributes.attributes||(e[t]=e.attributes[t]);e.attributes.attributes?e.attributes=e.attributes.attributes:delete e.attributes}return e}; |
@@ -1,1 +0,1 @@ | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./deattribute.js");require("./error.js"),require("./filterIncludes.js");var t=require("./linkRelationships.js");exports.deserialise=function(i){var a,r;if(i)return Array.isArray(i.data)?i=function(i){for(let a of i.data)i.included&&(a=t.linkRelationships(a,i.included)),a.relationships&&(a=t.linkRelationships(a)),a.attributes&&(a=e.deattribute(a)),i.data[i.data.indexOf(a)]=a;return i}(i):i.included?i.data=t.linkRelationships(i.data,i.included):(null===(a=i.data)||void 0===a?void 0:a.constructor)===Object&&(i.data=t.linkRelationships(i.data)),delete i.included,(null===(r=i.data)||void 0===r?void 0:r.attributes)&&(i.data=e.deattribute(i.data)),i}; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./deattribute.js");require("./error.js"),require("./filterIncludes.js");var t=require("./linkRelationships.js");exports.deserialise=function(i){var a,r;if(i)return Array.isArray(i.data)?i=function(i){for(let a of i.data)i.included&&(a=t.linkRelationships(a,i.included)),a.relationships&&(a=t.linkRelationships(a)),a.attributes&&(a=e.deattribute(a)),i.data[i.data.indexOf(a)]=a;return i}(i):i.included?i.data=t.linkRelationships(i.data,i.included):(null===(a=i.data)||void 0===a?void 0:a.constructor)===Object&&(i.data=t.linkRelationships(i.data)),delete i.included,null!==(r=i.data)&&void 0!==r&&r.attributes&&(i.data=e.deattribute(i.data)),i}; |
@@ -1,1 +0,1 @@ | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.error=function(r){if(r.response){const e=r.response.data;(null==e?void 0:e.errors)&&(r.errors=e.errors)}throw r}; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.error=function(r){if(r.response){const e=r.response.data;null!=e&&e.errors&&(r.errors=e.errors)}throw r}; |
@@ -1,1 +0,1 @@ | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./error.js");exports.filterIncludes=function(r,{id:t,type:i}){try{if(t&&i){const e=r.filter(e=>e.id===t&&e.type===i)[0]||{id:t,type:i};return Object.assign({},e)}return{}}catch(r){e.error(r)}}; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./error.js");exports.filterIncludes=function(r,{id:t,type:i}){try{if(t&&i){const e=r.filter((e=>e.id===t&&e.type===i))[0]||{id:t,type:i};return Object.assign({},e)}return{}}catch(r){e.error(r)}}; |
@@ -1,1 +0,1 @@ | ||
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t=t||self).kitsuCore={})}(this,(function(t){"use strict";function e(t){var r;if("object"==typeof t&&null!==t)if(Array.isArray(t))t.map(t=>e(t));else if((null===(r=t.attributes)||void 0===r?void 0:r.constructor)===Object){for(const e of Object.keys(t.attributes))t.attributes.attributes||(t[e]=t.attributes[e]);t.attributes.attributes?t.attributes=t.attributes.attributes:delete t.attributes}return t}function r(t){if(t.response){const e=t.response.data;(null==e?void 0:e.errors)&&(t.errors=e.errors)}throw t}function n(t,{id:e,type:n}){try{if(e&&n){const r=t.filter(t=>t.id===e&&t.type===n)[0]||{id:e,type:n};return Object.assign({},r)}return{}}catch(t){r(t)}}function i({id:t,type:r,meta:i},o){const a=n(o,{id:t,type:r});return a.relationships&&l(a,o),i&&(a.meta=i),e(a)}function o(t,e,r){t[r]={},t.relationships[r].links&&(t[r].links=t.relationships[r].links),t[r].data=[];for(const n of t.relationships[r].data)t[r].data.push(i(n,e));delete t.relationships[r]}function a(t,e,r){t[r]={},t[r].data=i(t.relationships[r].data,e),t.relationships[r].links&&(t[r].links=t.relationships[r].links),delete t.relationships[r]}function s(t,e){t[e]={},t.relationships[e].links&&(t[e].links=t.relationships[e].links),delete t.relationships[e]}function l(t,e=[]){const{relationships:r}=t;for(const i in r){var n;Array.isArray(null===(n=r[i])||void 0===n?void 0:n.data)?o(t,e,i):r[i].data?a(t,e,i):s(t,i)}return 0===Object.keys(r||[]).length&&(null==r?void 0:r.constructor)===Object&&delete t.relationships,t}function u(t,e=null){const r=[];for(const o in t)Object.prototype.hasOwnProperty.call(t,o)&&r.push((n=t[o],i=e?"".concat(e,"[").concat(o,"]"):o,null!==n&&"object"==typeof n?u(n,i):encodeURIComponent(i)+"="+encodeURIComponent(n)));var n,i;return r.join("&")}function c(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},o=Object.keys(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}function d(t,e,r,n){const i=new Error("".concat(n," requires an ID for the ").concat(e," type"));if(void 0===e)throw new Error("".concat(n," requires a resource type"));if(t){if("POST"!==n&&r.length>0)for(const t of r)if(!t.id)throw i}else{if("object"!=typeof r||0===Object.keys(r).length)throw new Error("".concat(n," requires an object or array body"));if("POST"!==n&&!r.id)throw i}}function p(t,e,r){e[r]={data:{}};for(const n of Object.keys(t[r].data)){const i=t[r].data[n];let o=e[r].data;n&&!["id","type"].includes(n)?o=O(i,n,o):o[n]=i}return e}function f(t,e,r){e[r]={data:[]};for(const n of t[r].data)e[r].data.push(n);return e}function y(t){let e={};for(const r in t){e=Array.isArray(t[r].data)?f(t,e,r):p(t,e,r)}return e}function h(t,e,r,n){return n.relationships||(n.relationships={}),t.type||(t.type=e),n.relationships[r]={data:Object.assign(t)},n.relationships=y(n.relationships),n}function b(t,e,r,n){return n.relationships||(n.relationships={}),n.relationships[r]={data:t.map(t=>{let{id:r,type:n}=t,i=c(t,["id","type"]);return{id:r,type:n||e,attributes:Object.keys(i).length?i:void 0}})},n.relationships=y(n.relationships),n}function O(t,e,r){return r.attributes||(r.attributes={}),r.attributes[e]=t,r}function j(t){return Object.prototype.hasOwnProperty.call(t,"id")}function v(t,e,r,n){d(!1,t,e,r);let i={type:t=n.pluralTypes(n.camelCaseTypes(t))};(null==e?void 0:e.id)&&(i.id=String(e.id));for(const t in e){const r=e[t],o=n.pluralTypes(n.camelCaseTypes(t));null!==r&&(null==r?void 0:r.constructor)===Object&&j(r)?i=h(r,o,t,i):null!==r&&Array.isArray(r)&&r.length>0&&j(r[0])?i=b(r,o,t,i):"id"!==t&&"type"!==t&&(i=O(r,t,i))}return{data:i}}t.camel=t=>t.replace(/[-_][a-z\u00E0-\u00F6\u00F8-\u00FE]/g,t=>t.slice(1).toUpperCase()),t.deattribute=e,t.deserialise=function(t){var r,n;if(t)return Array.isArray(t.data)?t=function(t){for(let r of t.data)t.included&&(r=l(r,t.included)),r.relationships&&(r=l(r)),r.attributes&&(r=e(r)),t.data[t.data.indexOf(r)]=r;return t}(t):t.included?t.data=l(t.data,t.included):(null===(r=t.data)||void 0===r?void 0:r.constructor)===Object&&(t.data=l(t.data)),delete t.included,(null===(n=t.data)||void 0===n?void 0:n.attributes)&&(t.data=e(t.data)),t},t.error=r,t.filterIncludes=n,t.kebab=t=>t.charAt(0).toLowerCase()+t.slice(1).replace(/[A-Z\u00C0-\u00D6\u00D8-\u00DE]/g,t=>"-"+t.toLowerCase()),t.linkRelationships=l,t.query=u,t.serialise=function(t,e={},n="POST",i={}){try{return i.camelCaseTypes||(i.camelCaseTypes=t=>t),i.pluralTypes||(i.pluralTypes=t=>t),null===e||Array.isArray(e)&&0===e.length?{data:e}:Array.isArray(e)&&(null==e?void 0:e.length)>0?function(t,e,r,n){d(!0,t,e,r);const i=[];for(const o of e)i.push(v(t,o,r,n).data);return{data:i}}(t,e,n,i):v(t,e,n,i)}catch(t){throw r(t)}},t.snake=t=>t.charAt(0).toLowerCase()+t.slice(1).replace(/[A-Z\u00C0-\u00D6\u00D8-\u00DE]/g,t=>"_"+t.toLowerCase()),t.splitModel=function(t,e={}){e.pluralModel||(e.pluralModel=t=>t),e.resourceCase||(e.resourceCase=t=>t);const r=t.split("/"),n=r.pop();return r.push(e.pluralModel(e.resourceCase(n))),[n,r.join("/")]},Object.defineProperty(t,"__esModule",{value:!0})})); | ||
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).kitsuCore={})}(this,(function(t){"use strict";function e(t){var r;if("object"==typeof t&&null!==t)if(Array.isArray(t))t.map((t=>e(t)));else if((null===(r=t.attributes)||void 0===r?void 0:r.constructor)===Object){for(const e of Object.keys(t.attributes))t.attributes.attributes||(t[e]=t.attributes[e]);t.attributes.attributes?t.attributes=t.attributes.attributes:delete t.attributes}return t}function r(t){if(t.response){const e=t.response.data;null!=e&&e.errors&&(t.errors=e.errors)}throw t}function n(t,{id:e,type:n}){try{if(e&&n){const r=t.filter((t=>t.id===e&&t.type===n))[0]||{id:e,type:n};return Object.assign({},r)}return{}}catch(t){r(t)}}function i({id:t,type:r,meta:i},a){const o=n(a,{id:t,type:r});return o.relationships&&l(o,a),i&&(o.meta=i),e(o)}function a(t,e,r){t[r]={},t.relationships[r].links&&(t[r].links=t.relationships[r].links),t[r].data=[];for(const n of t.relationships[r].data)t[r].data.push(i(n,e));delete t.relationships[r]}function o(t,e,r){t[r]={},t[r].data=i(t.relationships[r].data,e),t.relationships[r].links&&(t[r].links=t.relationships[r].links),delete t.relationships[r]}function s(t,e){t[e]={},t.relationships[e].links&&(t[e].links=t.relationships[e].links),delete t.relationships[e]}function l(t,e=[]){const{relationships:r}=t;for(const i in r){var n;Array.isArray(null===(n=r[i])||void 0===n?void 0:n.data)?a(t,e,i):r[i].data?o(t,e,i):s(t,i)}return 0===Object.keys(r||[]).length&&(null==r?void 0:r.constructor)===Object&&delete t.relationships,t}function u(t,e=null){const r=[];for(const a in t)Object.prototype.hasOwnProperty.call(t,a)&&r.push((n=t[a],i=e?"".concat(e,"[").concat(a,"]"):a,null!==n&&"object"==typeof n?u(n,i):encodeURIComponent(i)+"="+encodeURIComponent(n)));var n,i;return r.join("&")}function c(t,e,r,n){const i=new Error("".concat(n," requires an ID for the ").concat(e," type"));if(void 0===e)throw new Error("".concat(n," requires a resource type"));if(t){if("POST"!==n&&r.length>0)for(const t of r)if(!t.id)throw i}else{if("object"!=typeof r||0===Object.keys(r).length)throw new Error("".concat(n," requires an object or array body"));if("POST"!==n&&!r.id)throw i}}function d(t,e,r){e[r]={data:{}};for(const n of Object.keys(t[r].data)){const i=t[r].data[n];let a=e[r].data;n&&!["id","type"].includes(n)?a=b(i,n,a):a[n]=i}return e}function p(t,e,r){e[r]={data:[]};for(const n of t[r].data)e[r].data.push(n);return e}function f(t){let e={};for(const r in t){e=Array.isArray(t[r].data)?p(t,e,r):d(t,e,r)}return e}function y(t,e,r,n){return n.relationships||(n.relationships={}),t.type||(t.type=e),n.relationships[r]={data:Object.assign(t)},n.relationships=f(n.relationships),n}function h(t,e,r,n){return n.relationships||(n.relationships={}),n.relationships[r]={data:t.map((({id:t,type:r,...n})=>({id:t,type:r||e,attributes:Object.keys(n).length?n:void 0})))},n.relationships=f(n.relationships),n}function b(t,e,r){return r.attributes||(r.attributes={}),r.attributes[e]=t,r}function j(t){return Object.prototype.hasOwnProperty.call(t,"id")}function O(t,e,r,n){c(!1,t,e,r);let i={type:t=n.pluralTypes(n.camelCaseTypes(t))};null!=e&&e.id&&(i.id=String(e.id));for(const t in e){const r=e[t],a=n.pluralTypes(n.camelCaseTypes(t));null!==r&&(null==r?void 0:r.constructor)===Object&&j(r)?i=y(r,a,t,i):null!==r&&Array.isArray(r)&&r.length>0&&j(r[0])?i=h(r,a,t,i):"id"!==t&&"type"!==t&&(i=b(r,t,i))}return{data:i}}t.camel=t=>t.replace(/[-_][a-z\u00E0-\u00F6\u00F8-\u00FE]/g,(t=>t.slice(1).toUpperCase())),t.deattribute=e,t.deserialise=function(t){var r,n;if(t)return Array.isArray(t.data)?t=function(t){for(let r of t.data)t.included&&(r=l(r,t.included)),r.relationships&&(r=l(r)),r.attributes&&(r=e(r)),t.data[t.data.indexOf(r)]=r;return t}(t):t.included?t.data=l(t.data,t.included):(null===(r=t.data)||void 0===r?void 0:r.constructor)===Object&&(t.data=l(t.data)),delete t.included,null!==(n=t.data)&&void 0!==n&&n.attributes&&(t.data=e(t.data)),t},t.error=r,t.filterIncludes=n,t.kebab=t=>t.charAt(0).toLowerCase()+t.slice(1).replace(/[A-Z\u00C0-\u00D6\u00D8-\u00DE]/g,(t=>"-"+t.toLowerCase())),t.linkRelationships=l,t.query=u,t.serialise=function(t,e={},n="POST",i={}){try{return i.camelCaseTypes||(i.camelCaseTypes=t=>t),i.pluralTypes||(i.pluralTypes=t=>t),null===e||Array.isArray(e)&&0===e.length?{data:e}:Array.isArray(e)&&(null==e?void 0:e.length)>0?function(t,e,r,n){c(!0,t,e,r);const i=[];for(const a of e)i.push(O(t,a,r,n).data);return{data:i}}(t,e,n,i):O(t,e,n,i)}catch(t){throw r(t)}},t.snake=t=>t.charAt(0).toLowerCase()+t.slice(1).replace(/[A-Z\u00C0-\u00D6\u00D8-\u00DE]/g,(t=>"_"+t.toLowerCase())),t.splitModel=function(t,e={}){e.pluralModel||(e.pluralModel=t=>t),e.resourceCase||(e.resourceCase=t=>t);const r=t.split("/"),n=r.pop();return r.push(e.pluralModel(e.resourceCase(n))),[n,r.join("/")]},Object.defineProperty(t,"__esModule",{value:!0})})); |
@@ -1,1 +0,1 @@ | ||
"use strict";module.exports=e=>e.charAt(0).toLowerCase()+e.slice(1).replace(/[A-Z\u00C0-\u00D6\u00D8-\u00DE]/g,e=>"-"+e.toLowerCase()); | ||
"use strict";module.exports=e=>e.charAt(0).toLowerCase()+e.slice(1).replace(/[A-Z\u00C0-\u00D6\u00D8-\u00DE]/g,(e=>"-"+e.toLowerCase())); |
@@ -1,1 +0,1 @@ | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t=require("./error.js");function r(t,r){if(null==t)return{};var e,n,o=function(t,r){if(null==t)return{};var e,n,o={},a=Object.keys(t);for(n=0;n<a.length;n++)e=a[n],r.indexOf(e)>=0||(o[e]=t[e]);return o}(t,r);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(n=0;n<a.length;n++)e=a[n],r.indexOf(e)>=0||Object.prototype.propertyIsEnumerable.call(t,e)&&(o[e]=t[e])}return o}function e(t,r,e,n){const o=new Error("".concat(n," requires an ID for the ").concat(r," type"));if(void 0===r)throw new Error("".concat(n," requires a resource type"));if(t){if("POST"!==n&&e.length>0)for(const t of e)if(!t.id)throw o}else{if("object"!=typeof e||0===Object.keys(e).length)throw new Error("".concat(n," requires an object or array body"));if("POST"!==n&&!e.id)throw o}}function n(t,r,e){r[e]={data:{}};for(const n of Object.keys(t[e].data)){const o=t[e].data[n];let a=r[e].data;n&&!["id","type"].includes(n)?a=l(o,n,a):a[n]=o}return r}function o(t,r,e){r[e]={data:[]};for(const n of t[e].data)r[e].data.push(n);return r}function a(t){let r={};for(const e in t){r=Array.isArray(t[e].data)?o(t,r,e):n(t,r,e)}return r}function i(t,r,e,n){return n.relationships||(n.relationships={}),t.type||(t.type=r),n.relationships[e]={data:Object.assign(t)},n.relationships=a(n.relationships),n}function s(t,e,n,o){return o.relationships||(o.relationships={}),o.relationships[n]={data:t.map(t=>{let{id:n,type:o}=t,a=r(t,["id","type"]);return{id:n,type:o||e,attributes:Object.keys(a).length?a:void 0}})},o.relationships=a(o.relationships),o}function l(t,r,e){return e.attributes||(e.attributes={}),e.attributes[r]=t,e}function c(t){return Object.prototype.hasOwnProperty.call(t,"id")}function u(t,r,n,o){e(!1,t,r,n);let a={type:t=o.pluralTypes(o.camelCaseTypes(t))};(null==r?void 0:r.id)&&(a.id=String(r.id));for(const t in r){const e=r[t],n=o.pluralTypes(o.camelCaseTypes(t));null!==e&&(null==e?void 0:e.constructor)===Object&&c(e)?a=i(e,n,t,a):null!==e&&Array.isArray(e)&&e.length>0&&c(e[0])?a=s(e,n,t,a):"id"!==t&&"type"!==t&&(a=l(e,t,a))}return{data:a}}exports.serialise=function(r,n={},o="POST",a={}){try{return a.camelCaseTypes||(a.camelCaseTypes=t=>t),a.pluralTypes||(a.pluralTypes=t=>t),null===n||Array.isArray(n)&&0===n.length?{data:n}:Array.isArray(n)&&(null==n?void 0:n.length)>0?function(t,r,n,o){e(!0,t,r,n);const a=[];for(const e of r)a.push(u(t,e,n,o).data);return{data:a}}(r,n,o,a):u(r,n,o,a)}catch(r){throw t.error(r)}}; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t=require("./error.js");function r(t,r,e,n){const a=new Error("".concat(n," requires an ID for the ").concat(r," type"));if(void 0===r)throw new Error("".concat(n," requires a resource type"));if(t){if("POST"!==n&&e.length>0)for(const t of e)if(!t.id)throw a}else{if("object"!=typeof e||0===Object.keys(e).length)throw new Error("".concat(n," requires an object or array body"));if("POST"!==n&&!e.id)throw a}}function e(t,r,e){r[e]={data:{}};for(const n of Object.keys(t[e].data)){const a=t[e].data[n];let o=r[e].data;n&&!["id","type"].includes(n)?o=i(a,n,o):o[n]=a}return r}function n(t,r,e){r[e]={data:[]};for(const n of t[e].data)r[e].data.push(n);return r}function a(t){let r={};for(const a in t){r=Array.isArray(t[a].data)?n(t,r,a):e(t,r,a)}return r}function o(t,r,e,n){return n.relationships||(n.relationships={}),t.type||(t.type=r),n.relationships[e]={data:Object.assign(t)},n.relationships=a(n.relationships),n}function s(t,r,e,n){return n.relationships||(n.relationships={}),n.relationships[e]={data:t.map((({id:t,type:e,...n})=>({id:t,type:e||r,attributes:Object.keys(n).length?n:void 0})))},n.relationships=a(n.relationships),n}function i(t,r,e){return e.attributes||(e.attributes={}),e.attributes[r]=t,e}function c(t){return Object.prototype.hasOwnProperty.call(t,"id")}function l(t,e,n,a){r(!1,t,e,n);let l={type:t=a.pluralTypes(a.camelCaseTypes(t))};null!=e&&e.id&&(l.id=String(e.id));for(const t in e){const r=e[t],n=a.pluralTypes(a.camelCaseTypes(t));null!==r&&(null==r?void 0:r.constructor)===Object&&c(r)?l=o(r,n,t,l):null!==r&&Array.isArray(r)&&r.length>0&&c(r[0])?l=s(r,n,t,l):"id"!==t&&"type"!==t&&(l=i(r,t,l))}return{data:l}}exports.serialise=function(e,n={},a="POST",o={}){try{return o.camelCaseTypes||(o.camelCaseTypes=t=>t),o.pluralTypes||(o.pluralTypes=t=>t),null===n||Array.isArray(n)&&0===n.length?{data:n}:Array.isArray(n)&&(null==n?void 0:n.length)>0?function(t,e,n,a){r(!0,t,e,n);const o=[];for(const r of e)o.push(l(t,r,n,a).data);return{data:o}}(e,n,a,o):l(e,n,a,o)}catch(r){throw t.error(r)}}; |
@@ -1,1 +0,1 @@ | ||
"use strict";module.exports=e=>e.charAt(0).toLowerCase()+e.slice(1).replace(/[A-Z\u00C0-\u00D6\u00D8-\u00DE]/g,e=>"_"+e.toLowerCase()); | ||
"use strict";module.exports=e=>e.charAt(0).toLowerCase()+e.slice(1).replace(/[A-Z\u00C0-\u00D6\u00D8-\u00DE]/g,(e=>"_"+e.toLowerCase())); |
{ | ||
"version": "9.1.16", | ||
"version": "9.1.17", | ||
"name": "kitsu-core", | ||
@@ -60,3 +60,3 @@ "description": "Simple, lightweight & framework agnostic JSON:API (de)serialsation components", | ||
], | ||
"gitHead": "582d319c5f3b3feec935d8973655b62892d54971", | ||
"gitHead": "c7d71b9c910c608de00fa2241ff8a15ff49ad26e", | ||
"devDependencies": { | ||
@@ -63,0 +63,0 @@ "@size-limit/preset-small-lib": "~4.5.0" |
@@ -117,3 +117,3 @@ <h1 align=center>Kitsu Core</h1> | ||
[packages/kitsu-core/src/deattribute/index.js:29-51](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/deattribute/index.js#L29-L51 "Source code on GitHub") | ||
[packages/kitsu-core/src/deattribute/index.js:29-51](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/deattribute/index.js#L29-L51 "Source code on GitHub") | ||
@@ -162,3 +162,3 @@ Hoists attributes to be top-level | ||
[packages/kitsu-core/src/deserialise/index.js:57-72](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/deserialise/index.js#L57-L72 "Source code on GitHub") | ||
[packages/kitsu-core/src/deserialise/index.js:57-72](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/deserialise/index.js#L57-L72 "Source code on GitHub") | ||
@@ -215,3 +215,3 @@ Deserialises a JSON-API response | ||
[packages/kitsu-core/src/error/index.js:27-33](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/error/index.js#L27-L33 "Source code on GitHub") | ||
[packages/kitsu-core/src/error/index.js:27-33](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/error/index.js#L27-L33 "Source code on GitHub") | ||
@@ -253,3 +253,3 @@ Uniform error handling for Axios, JSON:API and internal package errors. Mutated Error object is rethrown to the caller. | ||
[packages/kitsu-core/src/filterIncludes/index.js:33-46](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/filterIncludes/index.js#L33-L46 "Source code on GitHub") | ||
[packages/kitsu-core/src/filterIncludes/index.js:33-46](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/filterIncludes/index.js#L33-L46 "Source code on GitHub") | ||
@@ -293,3 +293,3 @@ Filters includes for the specific relationship requested | ||
[packages/kitsu-core/src/linkRelationships/index.js:97-117](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/linkRelationships/index.js#L97-L117 "Source code on GitHub") | ||
[packages/kitsu-core/src/linkRelationships/index.js:97-117](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/linkRelationships/index.js#L97-L117 "Source code on GitHub") | ||
@@ -332,3 +332,3 @@ Links relationships to included data | ||
[packages/kitsu-core/src/query/index.js:33-44](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/query/index.js#L33-L44 "Source code on GitHub") | ||
[packages/kitsu-core/src/query/index.js:33-44](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/query/index.js#L33-L44 "Source code on GitHub") | ||
@@ -361,3 +361,3 @@ Constructs a URL query string for JSON:API parameters | ||
[packages/kitsu-core/src/serialise/index.js:249-260](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/serialise/index.js#L249-L260 "Source code on GitHub") | ||
[packages/kitsu-core/src/serialise/index.js:249-260](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/serialise/index.js#L249-L260 "Source code on GitHub") | ||
@@ -408,3 +408,3 @@ Serialises an object into a JSON-API structure | ||
[packages/kitsu-core/src/splitModel/index.js:29-39](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/splitModel/index.js#L29-L39 "Source code on GitHub") | ||
[packages/kitsu-core/src/splitModel/index.js:29-39](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/splitModel/index.js#L29-L39 "Source code on GitHub") | ||
@@ -452,3 +452,3 @@ Split model name from the model's resource URL | ||
[packages/kitsu-core/src/camel/index.js:14-14](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/camel/index.js#L14-L14 "Source code on GitHub") | ||
[packages/kitsu-core/src/camel/index.js:14-14](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/camel/index.js#L14-L14 "Source code on GitHub") | ||
@@ -481,3 +481,3 @@ Converts kebab-case and snake_case into camelCase | ||
[packages/kitsu-core/src/kebab/index.js:11-11](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/kebab/index.js#L11-L11 "Source code on GitHub") | ||
[packages/kitsu-core/src/kebab/index.js:11-11](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/kebab/index.js#L11-L11 "Source code on GitHub") | ||
@@ -500,3 +500,3 @@ Converts camelCase into kebab-case | ||
[packages/kitsu-core/src/snake/index.js:11-11](https://github.com/wopian/kitsu/blob/1015412d29679a4c4666598dbb6a7ad907d8c391/packages/kitsu-core/src/snake/index.js#L11-L11 "Source code on GitHub") | ||
[packages/kitsu-core/src/snake/index.js:11-11](https://github.com/wopian/kitsu/blob/d733c6351273481aa9207366784e3c8748681fa3/packages/kitsu-core/src/snake/index.js#L11-L11 "Source code on GitHub") | ||
@@ -503,0 +503,0 @@ Converts camelCase into snake_case |
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
65624
336