@polkadot-api/utils
Advanced tools
Comparing version 0.0.1-805bace16427baa1d9080f8749a5ced654fa7acd.1.0 to 0.0.1-8085034060d643c71d85df47784513b07a0a247c.1.0
@@ -16,2 +16,6 @@ declare function toHex(bytes: Uint8Array): string; | ||
export { fromHex, mapObject, mapStringRecord, mergeUint8, noop, toHex }; | ||
declare class AbortError extends Error { | ||
constructor(); | ||
} | ||
export { AbortError, fromHex, mapObject, mapStringRecord, mergeUint8, noop, toHex }; |
@@ -23,2 +23,3 @@ "use strict"; | ||
__export(src_exports, { | ||
AbortError: () => AbortError, | ||
fromHex: () => fromHex, | ||
@@ -110,2 +111,10 @@ mapObject: () => mapObject, | ||
var noop = Function.prototype; | ||
// src/AbortError.ts | ||
var AbortError = class extends Error { | ||
constructor() { | ||
super("Abort Error"); | ||
this.name = "AbortError"; | ||
} | ||
}; | ||
//# sourceMappingURL=index.js.map |
@@ -16,2 +16,6 @@ declare function toHex(bytes: Uint8Array): string; | ||
export { fromHex, mapObject, mapStringRecord, mergeUint8, noop, toHex }; | ||
declare class AbortError extends Error { | ||
constructor(); | ||
} | ||
export { AbortError, fromHex, mapObject, mapStringRecord, mergeUint8, noop, toHex }; |
@@ -1,2 +0,2 @@ | ||
"use strict";var s=Object.defineProperty;var x=Object.getOwnPropertyDescriptor;var l=Object.getOwnPropertyNames;var R=Object.prototype.hasOwnProperty;var A=(t,r)=>{for(var e in r)s(t,e,{get:r[e],enumerable:!0})},I=(t,r,e,n)=>{if(r&&typeof r=="object"||typeof r=="function")for(let o of l(r))!R.call(t,o)&&o!==e&&s(t,o,{get:()=>r[o],enumerable:!(n=x(r,o))||n.enumerable});return t};var j=t=>I(s({},"__esModule",{value:!0}),t);var K={};A(K,{fromHex:()=>d,mapObject:()=>b,mapStringRecord:()=>f,mergeUint8:()=>g,noop:()=>u,toHex:()=>p});module.exports=j(K);var m="0123456789abcdef";function p(t){let r=new Array(t.length+1);r[0]="0x";for(let e=0;e<t.length;){let n=t[e++];r[e]=m[n>>4]+m[n&15]}return r.join("")}var i={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,b:11,c:12,d:13,e:14,f:15,A:10,B:11,C:12,D:13,E:14,F:15};function d(t){let r=t.length%2,e=(t[1]==="x"?2:0)+r,n=(t.length-e)/2+r,o=new Uint8Array(n);r&&(o[0]=0|i[t[2]]);for(let c=0;c<n;){let a=e+c*2,y=i[t[a]],O=i[t[a+1]];o[r+c++]=y<<4|O}return o}function b(t,r){return Object.fromEntries(Object.entries(t).map(([e,n])=>[e,r(n,e)]))}var f=(t,r)=>Object.fromEntries(Object.entries(t).map(([e,n])=>[e,r(n,e)]));var g=(...t)=>{let r=t.reduce((n,o)=>n+o.byteLength,0),e=new Uint8Array(r);for(let n=0,o=0;n<t.length;n++){let c=t[n];e.set(c,o),o+=c.byteLength}return e};var u=Function.prototype; | ||
"use strict";var i=Object.defineProperty;var l=Object.getOwnPropertyDescriptor;var A=Object.getOwnPropertyNames;var R=Object.prototype.hasOwnProperty;var I=(r,t)=>{for(var e in t)i(r,e,{get:t[e],enumerable:!0})},j=(r,t,e,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of A(t))!R.call(r,o)&&o!==e&&i(r,o,{get:()=>t[o],enumerable:!(n=l(t,o))||n.enumerable});return r};var E=r=>j(i({},"__esModule",{value:!0}),r);var K={};I(K,{AbortError:()=>s,fromHex:()=>d,mapObject:()=>u,mapStringRecord:()=>x,mergeUint8:()=>f,noop:()=>g,toHex:()=>b});module.exports=E(K);var p="0123456789abcdef";function b(r){let t=new Array(r.length+1);t[0]="0x";for(let e=0;e<r.length;){let n=r[e++];t[e]=p[n>>4]+p[n&15]}return t.join("")}var a={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,b:11,c:12,d:13,e:14,f:15,A:10,B:11,C:12,D:13,E:14,F:15};function d(r){let t=r.length%2,e=(r[1]==="x"?2:0)+t,n=(r.length-e)/2+t,o=new Uint8Array(n);t&&(o[0]=0|a[r[2]]);for(let c=0;c<n;){let m=e+c*2,y=a[r[m]],O=a[r[m+1]];o[t+c++]=y<<4|O}return o}function u(r,t){return Object.fromEntries(Object.entries(r).map(([e,n])=>[e,t(n,e)]))}var x=(r,t)=>Object.fromEntries(Object.entries(r).map(([e,n])=>[e,t(n,e)]));var f=(...r)=>{let t=r.reduce((n,o)=>n+o.byteLength,0),e=new Uint8Array(t);for(let n=0,o=0;n<r.length;n++){let c=r[n];e.set(c,o),o+=c.byteLength}return e};var g=Function.prototype;var s=class extends Error{constructor(){super("Abort Error"),this.name="AbortError"}}; | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@polkadot-api/utils", | ||
"version": "0.0.1-805bace16427baa1d9080f8749a5ced654fa7acd.1.0", | ||
"version": "0.0.1-8085034060d643c71d85df47784513b07a0a247c.1.0", | ||
"author": "Josep M Sobrepere (https://github.com/josepot)", | ||
@@ -5,0 +5,0 @@ "repository": { |
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
25389
237