Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

kitsu-core

Package Overview
Dependencies
Maintainers
1
Versions
122
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

kitsu-core - npm Package Compare versions

Comparing version 7.0.0 to 7.0.1

11

CHANGELOG.md

@@ -6,2 +6,13 @@ # Change Log

## [7.0.1](https://github.com/wopian/kitsu/tree/master/packages/kitsu-core/compare/v7.0.0...v7.0.1) (2019-04-15)
### Chores
* **release:** update documentation ([60e15f9](https://github.com/wopian/kitsu/tree/master/packages/kitsu-core/commit/60e15f9))
# [7.0.0](https://github.com/wopian/kitsu/tree/master/packages/kitsu-core/compare/v6.2.3...v7.0.0) (2019-03-02)

@@ -8,0 +19,0 @@

565

lib/index.js

@@ -5,48 +5,6 @@ 'use strict';

function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
var _regeneratorRuntime = _interopDefault(require('@babel/runtime/regenerator'));
function deattribute(data) {
return _regeneratorRuntime.async(function (_context2) {
for (;;) switch (_context2.prev = _context2.next) {
case 0:
if (_context2.t0 = 'object' === typeof data && null !== data, !_context2.t0) {
_context2.next = 8;
break;
}
if (!Array.isArray(data)) {
_context2.next = 7;
break;
}
return _context2.next = 5, _regeneratorRuntime.awrap(data.map(el => _regeneratorRuntime.async(function (_context) {
for (;;) switch (_context.prev = _context.next) {
case 0:
return _context.abrupt("return", deattribute(el));
case 1:
case "end":
return _context.stop();
}
}, null, this)));
case 5:
_context2.next = 8;
break;
case 7:
data.attributes && data.attributes.constructor === Object && (Object.keys(data.attributes).forEach(key => {
data[key] = data.attributes[key];
}), delete data.attributes);
case 8:
return _context2.abrupt("return", data);
case 9:
case "end":
return _context2.stop();
}
}, null, this);
async function deattribute(data) {
return 'object' === typeof data && null !== data && (Array.isArray(data) ? await data.map(async el => deattribute(el)) : data.attributes && data.attributes.constructor === Object && (Object.keys(data.attributes).forEach(key => {
data[key] = data.attributes[key];
}), delete data.attributes)), data;
}

@@ -63,299 +21,55 @@

function filterIncludes(included, _ref) {
var id, type, filtered;
return _regeneratorRuntime.async(function (_context) {
for (;;) switch (_context.prev = _context.next) {
case 0:
return id = _ref.id, type = _ref.type, _context.prev = 1, filtered = included.filter(el => el.id === id && el.type === type)[0] || {
id,
type
}, _context.abrupt("return", Object.assign({}, filtered));
async function filterIncludes(included, _ref) {
let id = _ref.id,
type = _ref.type;
case 6:
_context.prev = 6, _context.t0 = _context["catch"](1), error(_context.t0);
case 9:
case "end":
return _context.stop();
}
}, null, this, [[1, 6]]);
try {
const filtered = included.filter(el => el.id === id && el.type === type)[0] || {
id,
type
};
return Object.assign({}, filtered);
} catch (E) {
error(E);
}
}
function link(_ref, included) {
var id, type, meta, filtered;
return _regeneratorRuntime.async(function (_context) {
for (;;) switch (_context.prev = _context.next) {
case 0:
return id = _ref.id, type = _ref.type, meta = _ref.meta, _context.next = 3, _regeneratorRuntime.awrap(filterIncludes(included, {
id,
type
}));
case 3:
if (filtered = _context.sent, _context.t0 = filtered.relationships, !_context.t0) {
_context.next = 8;
break;
}
return _context.next = 8, _regeneratorRuntime.awrap(linkRelationships(filtered, included));
case 8:
return meta && (filtered.meta = meta), _context.abrupt("return", deattribute(filtered));
case 10:
case "end":
return _context.stop();
}
}, null, this);
async function link(_ref, included) {
let id = _ref.id,
type = _ref.type,
meta = _ref.meta;
const filtered = await filterIncludes(included, {
id,
type
});
return filtered.relationships && (await linkRelationships(filtered, included)), meta && (filtered.meta = meta), deattribute(filtered);
}
function linkArray(data, included, key) {
var _iteratorNormalCompletion, _didIteratorError, _iteratorError, _step, _iterator, resource;
async function linkArray(data, included, key) {
data[key] = [];
return _regeneratorRuntime.async(function (_context2) {
for (;;) switch (_context2.prev = _context2.next) {
case 0:
return data[key] = [], _iteratorNormalCompletion = !0, _didIteratorError = !1, _iteratorError = void 0, _context2.prev = 2, _context2.next = 5, _regeneratorRuntime.awrap(data.relationships[key].data);
case 5:
_context2.t0 = Symbol.iterator, _iterator = _context2.sent[_context2.t0]();
case 7:
if (_iteratorNormalCompletion = (_step = _iterator.next()).done) {
_context2.next = 17;
break;
}
return resource = _step.value, _context2.t1 = data[key], _context2.next = 12, _regeneratorRuntime.awrap(link(resource, included));
case 12:
_context2.t2 = _context2.sent, _context2.t1.push.call(_context2.t1, _context2.t2);
case 14:
_iteratorNormalCompletion = !0, _context2.next = 7;
break;
case 17:
_context2.next = 22;
break;
case 19:
_context2.prev = 19, _context2.t3 = _context2["catch"](2), _didIteratorError = !0, _iteratorError = _context2.t3;
case 22:
_context2.prev = 22, _context2.prev = 23, _iteratorNormalCompletion || null == _iterator.return || _iterator.return();
case 25:
if (_context2.prev = 25, !_didIteratorError) {
_context2.next = 28;
break;
}
throw _iteratorError;
case 28:
return _context2.finish(25);
case 29:
return _context2.finish(22);
case 30:
case "end":
return _context2.stop();
}
}, null, this, [[2, 19, 22, 30], [23,, 25, 29]]);
for (let resource of await data.relationships[key].data) data[key].push((await link(resource, included)));
}
function linkObject(data, included, key) {
return _regeneratorRuntime.async(function (_context3) {
for (;;) switch (_context3.prev = _context3.next) {
case 0:
return _context3.next = 2, _regeneratorRuntime.awrap(link(data.relationships[key].data, included));
case 2:
data[key] = _context3.sent, delete data[key].relationships;
case 4:
case "end":
return _context3.stop();
}
}, null, this);
async function linkObject(data, included, key) {
data[key] = await link(data.relationships[key].data, included), delete data[key].relationships;
}
function linkRelationships(data, included) {
var relationships, removeRelationships, key;
return _regeneratorRuntime.async(function (_context4) {
for (;;) switch (_context4.prev = _context4.next) {
case 0:
return relationships = data.relationships, removeRelationships = !1, _context4.next = 4, _regeneratorRuntime.awrap(relationships);
async function linkRelationships(data, included) {
const relationships = data.relationships;
let removeRelationships = !1;
case 4:
_context4.t0 = _regeneratorRuntime.keys(_context4.sent);
for (let key in await relationships) relationships[key].data && Array.isArray(relationships[key].data) ? (await linkArray(data, included, key), removeRelationships = !0) : relationships[key].data && (await linkObject(data, included, key), removeRelationships = !0);
case 5:
if ((_context4.t1 = _context4.t0()).done) {
_context4.next = 20;
break;
}
if (key = _context4.t1.value, !(relationships[key].data && Array.isArray(relationships[key].data))) {
_context4.next = 13;
break;
}
return _context4.next = 10, _regeneratorRuntime.awrap(linkArray(data, included, key));
case 10:
removeRelationships = !0, _context4.next = 18;
break;
case 13:
if (_context4.t2 = relationships[key].data, !_context4.t2) {
_context4.next = 18;
break;
}
return _context4.next = 17, _regeneratorRuntime.awrap(linkObject(data, included, key));
case 17:
removeRelationships = !0;
case 18:
_context4.next = 5;
break;
case 20:
return _context4.abrupt("return", (removeRelationships && delete data.relationships, data));
case 21:
case "end":
return _context4.stop();
}
}, null, this);
return removeRelationships && delete data.relationships, data;
}
function deserialiseArray(obj) {
var _iteratorNormalCompletion, _didIteratorError, _iteratorError, _step, _iterator, value;
async function deserialiseArray(obj) {
for (let value of await obj.data) obj.included && (value = await linkRelationships(value, obj.included)), value.attributes && (value = await deattribute(value)), obj.data[obj.data.indexOf(value)] = value;
return _regeneratorRuntime.async(function (_context) {
for (;;) switch (_context.prev = _context.next) {
case 0:
return _iteratorNormalCompletion = !0, _didIteratorError = !1, _iteratorError = void 0, _context.prev = 1, _context.next = 4, _regeneratorRuntime.awrap(obj.data);
case 4:
_context.t0 = Symbol.iterator, _iterator = _context.sent[_context.t0]();
case 6:
if (_iteratorNormalCompletion = (_step = _iterator.next()).done) {
_context.next = 22;
break;
}
if (value = _step.value, _context.t1 = obj.included, !_context.t1) {
_context.next = 13;
break;
}
return _context.next = 12, _regeneratorRuntime.awrap(linkRelationships(value, obj.included));
case 12:
value = _context.sent;
case 13:
if (_context.t2 = value.attributes, !_context.t2) {
_context.next = 18;
break;
}
return _context.next = 17, _regeneratorRuntime.awrap(deattribute(value));
case 17:
value = _context.sent;
case 18:
obj.data[obj.data.indexOf(value)] = value;
case 19:
_iteratorNormalCompletion = !0, _context.next = 6;
break;
case 22:
_context.next = 27;
break;
case 24:
_context.prev = 24, _context.t3 = _context["catch"](1), _didIteratorError = !0, _iteratorError = _context.t3;
case 27:
_context.prev = 27, _context.prev = 28, _iteratorNormalCompletion || null == _iterator.return || _iterator.return();
case 30:
if (_context.prev = 30, !_didIteratorError) {
_context.next = 33;
break;
}
throw _iteratorError;
case 33:
return _context.finish(30);
case 34:
return _context.finish(27);
case 35:
return _context.abrupt("return", obj);
case 36:
case "end":
return _context.stop();
}
}, null, this, [[1, 24, 27, 35], [28,, 30, 34]]);
return obj;
}
function deserialise(obj) {
return _regeneratorRuntime.async(function (_context2) {
for (;;) switch (_context2.prev = _context2.next) {
case 0:
if (!(obj.data && obj.data.constructor === Array)) {
_context2.next = 6;
break;
}
return _context2.next = 3, _regeneratorRuntime.awrap(deserialiseArray(obj));
case 3:
obj = _context2.sent, _context2.next = 11;
break;
case 6:
if (_context2.t0 = obj.included, !_context2.t0) {
_context2.next = 11;
break;
}
return _context2.next = 10, _regeneratorRuntime.awrap(linkRelationships(obj.data, obj.included));
case 10:
obj.data = _context2.sent;
case 11:
if (delete obj.included, _context2.t1 = obj.data && obj.data.attributes, !_context2.t1) {
_context2.next = 17;
break;
}
return _context2.next = 16, _regeneratorRuntime.awrap(deattribute(obj.data));
case 16:
obj.data = _context2.sent;
case 17:
return _context2.abrupt("return", obj);
case 18:
case "end":
return _context2.stop();
}
}, null, this);
async function deserialise(obj) {
return obj.data && obj.data.constructor === Array ? obj = await deserialiseArray(obj) : obj.included && (obj.data = await linkRelationships(obj.data, obj.included)), delete obj.included, obj.data && obj.data.attributes && (obj.data = await deattribute(obj.data)), obj;
}

@@ -371,3 +85,3 @@

for (const param in params) params.hasOwnProperty(param) && str.push(queryFormat(params[param], prefix ? `${prefix}[${param}]` : param));
for (const param in params) params.hasOwnProperty(param) && str.push(queryFormat(params[param], prefix ? "".concat(prefix, "[").concat(param, "]") : param));

@@ -377,165 +91,56 @@ return str.join('&');

const requiresID = (method, key) => `${method} requires an ID for the ${key} relationships`;
const requiresID = (method, key) => "".concat(method, " requires an ID for the ").concat(key, " relationships");
function isValid(obj, method, type) {
return _regeneratorRuntime.async(function (_context) {
for (;;) switch (_context.prev = _context.next) {
case 0:
if (obj.constructor === Object && 0 !== Object.keys(obj).length) {
_context.next = 2;
break;
}
throw new Error(`${method} requires a JSON object body`);
case 2:
if ('POST' === method || obj.id) {
_context.next = 4;
break;
}
throw new Error(`${method} requires an ID for the ${type} type`);
case 4:
case "end":
return _context.stop();
}
}, null, this);
async function isValid(obj, method, type) {
if (obj.constructor !== Object || 0 === Object.keys(obj).length) throw new Error("".concat(method, " requires a JSON object body"));
if ('POST' !== method && !obj.id) throw new Error("".concat(method, " requires an ID for the ").concat(type, " type"));
}
function serialiseObject(node, nodeType, key, data, method) {
return _regeneratorRuntime.async(function (_context2) {
for (;;) switch (_context2.prev = _context2.next) {
case 0:
if ('string' === typeof node.id) {
_context2.next = 2;
break;
}
throw new Error(requiresID(method, key));
case 2:
return _context2.abrupt("return", (data.relationships || (data.relationships = {}), node.type || (node.type = nodeType), data.relationships[key] = {
data: Object.assign(node)
}, data));
case 3:
case "end":
return _context2.stop();
}
}, null, this);
async function serialiseObject(node, nodeType, key, data, method) {
if ('string' !== typeof node.id) throw new Error(requiresID(method, key));
return data.relationships || (data.relationships = {}), node.type || (node.type = nodeType), data.relationships[key] = {
data: Object.assign(node)
}, data;
}
function serialiseArray(node, nodeType, key, data, method) {
return _regeneratorRuntime.async(function (_context3) {
for (;;) switch (_context3.prev = _context3.next) {
case 0:
return _context3.abrupt("return", (data.relationships || (data.relationships = {}), data.relationships[key] = {
data: node.map((_ref) => {
let id = _ref.id,
type = _ref.type;
if (!id) throw new Error(requiresID(method, key));
return {
id,
type: type || nodeType
};
})
}, data));
case 1:
case "end":
return _context3.stop();
}
}, null, this);
async function serialiseArray(node, nodeType, key, data, method) {
return data.relationships || (data.relationships = {}), data.relationships[key] = {
data: node.map((_ref) => {
let id = _ref.id,
type = _ref.type;
if (!id) throw new Error(requiresID(method, key));
return {
id,
type: type || nodeType
};
})
}, data;
}
function serialiseAttr(node, key, data) {
return _regeneratorRuntime.async(function (_context4) {
for (;;) switch (_context4.prev = _context4.next) {
case 0:
return _context4.abrupt("return", (data.attributes || (data.attributes = {}), data.attributes[key] = node, data));
case 1:
case "end":
return _context4.stop();
}
}, null, this);
async function serialiseAttr(node, key, data) {
return data.attributes || (data.attributes = {}), data.attributes[key] = node, data;
}
function serialise(model) {
var obj,
method,
type,
data,
key,
node,
nodeType,
_args5 = arguments;
return _regeneratorRuntime.async(function (_context5) {
for (;;) switch (_context5.prev = _context5.next) {
case 0:
return obj = 1 < _args5.length && void 0 !== _args5[1] ? _args5[1] : {}, method = 2 < _args5.length && void 0 !== _args5[2] ? _args5[2] : 'POST', _context5.prev = 1, type = this.plural(this.camel(model)), data = {
type
}, _context5.next = 6, _regeneratorRuntime.awrap(isValid(obj, method, type));
async function serialise(model) {
let obj = 1 < arguments.length && void 0 !== arguments[1] ? arguments[1] : {},
method = 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : 'POST';
case 6:
'POST' !== method && (data.id = obj.id + ""), _context5.t0 = _regeneratorRuntime.keys(obj);
try {
const type = this.plural(this.camel(model));
let data = {
type
};
case 8:
if ((_context5.t1 = _context5.t0()).done) {
_context5.next = 30;
break;
}
for (let key in await isValid(obj, method, type), 'POST' !== method && (data.id = obj.id + ""), obj) {
const node = obj[key],
nodeType = this.plural(this.camel(key));
null !== node && node.constructor === Object ? data = await serialiseObject(node, nodeType, key, data, method) : null !== node && Array.isArray(node) ? data = await serialiseArray(node, nodeType, key, data, method) : 'id' !== key && 'type' !== key && (data = await serialiseAttr(node, key, data));
}
if (key = _context5.t1.value, node = obj[key], nodeType = this.plural(this.camel(key)), null === node || node.constructor !== Object) {
_context5.next = 17;
break;
}
return _context5.next = 14, _regeneratorRuntime.awrap(serialiseObject(node, nodeType, key, data, method));
case 14:
data = _context5.sent, _context5.next = 28;
break;
case 17:
if (!(null !== node && Array.isArray(node))) {
_context5.next = 23;
break;
}
return _context5.next = 20, _regeneratorRuntime.awrap(serialiseArray(node, nodeType, key, data, method));
case 20:
data = _context5.sent, _context5.next = 28;
break;
case 23:
if (_context5.t2 = 'id' !== key && 'type' !== key, !_context5.t2) {
_context5.next = 28;
break;
}
return _context5.next = 27, _regeneratorRuntime.awrap(serialiseAttr(node, key, data));
case 27:
data = _context5.sent;
case 28:
_context5.next = 8;
break;
case 30:
return _context5.abrupt("return", {
data
});
case 33:
throw _context5.prev = 33, _context5.t3 = _context5["catch"](1), error(_context5.t3);
case 36:
case "end":
return _context5.stop();
}
}, null, this, [[1, 33]]);
return {
data
};
} catch (E) {
throw error(E);
}
}

@@ -550,4 +155,2 @@

exports.camel = index;
exports.kebab = index$1;
exports.snake = index$2;
exports.deattribute = deattribute;

@@ -557,4 +160,6 @@ exports.deserialise = deserialise;

exports.filterIncludes = filterIncludes;
exports.kebab = index$1;
exports.linkRelationships = linkRelationships;
exports.query = query;
exports.serialise = serialise;
exports.snake = index$2;

@@ -151,4 +151,2 @@ 'use strict';

exports.camel = index;
exports.kebab = index$1;
exports.snake = index$2;
exports.deattribute = deattribute;

@@ -158,4 +156,6 @@ exports.deserialise = deserialise;

exports.filterIncludes = filterIncludes;
exports.kebab = index$1;
exports.linkRelationships = linkRelationships;
exports.query = query;
exports.serialise = serialise;
exports.snake = index$2;
{
"version": "7.0.0",
"version": "7.0.1",
"name": "kitsu-core",

@@ -59,3 +59,4 @@ "description": "Core serialisation and deserialsation functions for the kitsu JSON:API client",

}
]
],
"gitHead": "5c9778d191d17d7c9790cfc6d0f4e983b4742a53"
}

@@ -43,6 +43,6 @@ <h1 align=center>Kitsu Core</h1>

| Package | Package<br> Size\* | Node | Chrome | Firefox | Safari | Edge | IE |
| ----------------: | :----------------: | :--: | :----: | :-----: | :----: | :--: | :-: |
| `kitsu-core` | ≤ 4.3 kb | 8+ | 57+ | 52+ | 10.1+ | 16+ | |
| `kitsu-core/node` | ≤ 1.1 kb | 8+ | | | | | |
| Package | Package<br> Size\* | Node | Chrome | Firefox | Safari | Edge |
| ----------------: | :----------------: | :--: | :----: | :-----: | :----: | :--: |
| `kitsu-core` | ≤ 1.2 kb | 8+ | 58+ | 60+ | 11+ | 16+ |
| `kitsu-core/node` | ≤ 1.1 kb | 8+ | | | | |

@@ -113,3 +113,3 @@ \* Including all dependencies, minified & gzipped<br>

[packages/kitsu-core/src/deattribute/index.js:29-38](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/packages/kitsu-core/src/deattribute/index.js#L29-L38 "Source code on GitHub")
[packages/kitsu-core/src/deattribute/index.js:29-38](https://github.com/wopian/kitsu/blob/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/deattribute/index.js#L29-L38 "Source code on GitHub")

@@ -158,3 +158,3 @@ Hoists attributes to be top-level

[packages/kitsu-core/src/deserialise/index.js:56-70](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/packages/kitsu-core/src/deserialise/index.js#L56-L70 "Source code on GitHub")
[packages/kitsu-core/src/deserialise/index.js:56-70](https://github.com/wopian/kitsu/blob/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/deserialise/index.js#L56-L70 "Source code on GitHub")

@@ -211,3 +211,3 @@ Deserialises a JSON-API response

[packages/kitsu-core/src/error/index.js:7-13](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/packages/kitsu-core/src/error/index.js#L7-L13 "Source code on GitHub")
[packages/kitsu-core/src/error/index.js:7-13](https://github.com/wopian/kitsu/blob/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/error/index.js#L7-L13 "Source code on GitHub")

@@ -225,3 +225,3 @@ Mutates an error and rethrows it

[packages/kitsu-core/src/filterIncludes/index.js:12-21](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/packages/kitsu-core/src/filterIncludes/index.js#L12-L21 "Source code on GitHub")
[packages/kitsu-core/src/filterIncludes/index.js:12-21](https://github.com/wopian/kitsu/blob/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/filterIncludes/index.js#L12-L21 "Source code on GitHub")

@@ -241,3 +241,3 @@ Filters includes for the specific relationship

[packages/kitsu-core/src/linkRelationships/index.js:55-74](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/packages/kitsu-core/src/linkRelationships/index.js#L55-L74 "Source code on GitHub")
[packages/kitsu-core/src/linkRelationships/index.js:55-74](https://github.com/wopian/kitsu/blob/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/linkRelationships/index.js#L55-L74 "Source code on GitHub")

@@ -253,3 +253,3 @@ Links relationships to included data

[packages/kitsu-core/src/query/index.js:21-32](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/packages/kitsu-core/src/query/index.js#L21-L32 "Source code on GitHub")
[packages/kitsu-core/src/query/index.js:21-32](https://github.com/wopian/kitsu/blob/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/query/index.js#L21-L32 "Source code on GitHub")

@@ -267,3 +267,3 @@ Constructs a URL query string for JSON:API parameters

[packages/kitsu-core/src/serialise/index.js:96-121](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/packages/kitsu-core/src/serialise/index.js#L96-L121 "Source code on GitHub")
[packages/kitsu-core/src/serialise/index.js:96-121](https://github.com/wopian/kitsu/blob/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/serialise/index.js#L96-L121 "Source code on GitHub")

@@ -294,3 +294,3 @@ Serialises an object into a JSON-API structure

[packages/kitsu-core/src/camel/index.js:14-14](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/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/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/camel/index.js#L14-L14 "Source code on GitHub")

@@ -323,3 +323,3 @@ Converts kebab-case and snake_case into camelCase

[packages/kitsu-core/src/kebab/index.js:11-11](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/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/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/kebab/index.js#L11-L11 "Source code on GitHub")

@@ -342,3 +342,3 @@ Converts camelCase into kebab-case

[packages/kitsu-core/src/snake/index.js:11-11](https://github.com/wopian/kitsu/blob/07d2acab9cf767063713d2d30061a96e2c16db55/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/9ccf9d2881390959c5a016e514fdff742a41f0ce/packages/kitsu-core/src/snake/index.js#L11-L11 "Source code on GitHub")

@@ -345,0 +345,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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc