@steemit/steem-js 0.8.0 → 1.0.1

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.
Files changed (128) hide show
  1. package/README.md +202 -105
  2. package/dist/api/index.d.ts +128 -0
  3. package/dist/api/methods.d.ts +9 -0
  4. package/dist/api/rpc-auth.d.ts +43 -0
  5. package/dist/api/transports/base.d.ts +13 -0
  6. package/dist/api/transports/http.d.ts +9 -0
  7. package/dist/api/transports/index.d.ts +9 -0
  8. package/dist/api/transports/types.d.ts +35 -0
  9. package/dist/api/transports/ws.d.ts +18 -0
  10. package/dist/auth/ecc/index.d.ts +9 -0
  11. package/dist/auth/ecc/src/address.d.ts +13 -0
  12. package/dist/auth/ecc/src/aes.d.ts +16 -0
  13. package/dist/auth/ecc/src/brain_key.d.ts +1 -0
  14. package/dist/auth/ecc/src/ecdsa.d.ts +28 -0
  15. package/dist/auth/ecc/src/ecsignature.d.ts +19 -0
  16. package/dist/auth/ecc/src/enforce_types.d.ts +5 -0
  17. package/dist/auth/ecc/src/hash.d.ts +25 -0
  18. package/dist/auth/ecc/src/index.d.ts +9 -0
  19. package/dist/auth/ecc/src/key_private.d.ts +38 -0
  20. package/dist/auth/ecc/src/key_public.d.ts +41 -0
  21. package/dist/auth/ecc/src/key_utils.d.ts +9 -0
  22. package/dist/auth/ecc/src/signature.d.ts +18 -0
  23. package/dist/auth/ecc.d.ts +3 -0
  24. package/dist/auth/index.d.ts +48 -0
  25. package/dist/auth/key_classes.d.ts +3 -0
  26. package/dist/auth/serializer/transaction.d.ts +5 -0
  27. package/dist/auth/serializer.d.ts +19 -0
  28. package/dist/broadcast/helpers.d.ts +11 -0
  29. package/dist/broadcast/index.d.ts +43 -0
  30. package/dist/broadcast/operations.d.ts +6 -0
  31. package/dist/config.d.ts +27 -0
  32. package/dist/crypto/index.d.ts +25 -0
  33. package/dist/formatter/index.d.ts +92 -0
  34. package/dist/index.cjs +26436 -0
  35. package/dist/index.cjs.map +1 -0
  36. package/dist/index.d.ts +30 -0
  37. package/dist/index.js +26400 -0
  38. package/dist/index.js.map +1 -0
  39. package/dist/index.umd.js +58121 -0
  40. package/dist/index.umd.js.map +1 -0
  41. package/dist/memo/index.d.ts +11 -0
  42. package/dist/operations/index.d.ts +44 -0
  43. package/dist/serializer/convert.d.ts +12 -0
  44. package/dist/serializer/index.d.ts +11 -0
  45. package/dist/serializer/number_utils.d.ts +8 -0
  46. package/dist/serializer/precision.d.ts +5 -0
  47. package/dist/serializer/types.d.ts +36 -0
  48. package/dist/types/index.d.ts +131 -0
  49. package/dist/types.d.ts +34 -0
  50. package/dist/utils/debug.d.ts +36 -0
  51. package/dist/utils/index.d.ts +9 -0
  52. package/dist/utils.d.ts +2 -0
  53. package/package.json +68 -87
  54. package/.dockerignore +0 -12
  55. package/.editorconfig +0 -20
  56. package/.eslintrc +0 -27
  57. package/LICENSE +0 -21
  58. package/circle.yml +0 -3
  59. package/config.json +0 -10
  60. package/dist/steem-tests.min.js +0 -4097
  61. package/dist/steem.min.js +0 -2089
  62. package/docker-webpack.config.js +0 -44
  63. package/lib/api/index.js +0 -315
  64. package/lib/api/methods.js +0 -428
  65. package/lib/api/rpc-auth.js +0 -135
  66. package/lib/api/transports/base.js +0 -31
  67. package/lib/api/transports/http.js +0 -157
  68. package/lib/api/transports/index.js +0 -13
  69. package/lib/api/transports/ws.js +0 -128
  70. package/lib/auth/ecc/index.js +0 -13
  71. package/lib/auth/ecc/src/address.js +0 -54
  72. package/lib/auth/ecc/src/aes.js +0 -148
  73. package/lib/auth/ecc/src/brain_key.js +0 -13
  74. package/lib/auth/ecc/src/ecdsa.js +0 -193
  75. package/lib/auth/ecc/src/ecsignature.js +0 -102
  76. package/lib/auth/ecc/src/enforce_types.js +0 -42
  77. package/lib/auth/ecc/src/hash.js +0 -58
  78. package/lib/auth/ecc/src/key_private.js +0 -159
  79. package/lib/auth/ecc/src/key_public.js +0 -143
  80. package/lib/auth/ecc/src/key_utils.js +0 -70
  81. package/lib/auth/ecc/src/signature.js +0 -135
  82. package/lib/auth/index.js +0 -113
  83. package/lib/auth/memo.js +0 -119
  84. package/lib/auth/serializer/index.js +0 -15
  85. package/lib/auth/serializer/src/ChainTypes.js +0 -87
  86. package/lib/auth/serializer/src/convert.js +0 -34
  87. package/lib/auth/serializer/src/error_with_cause.js +0 -27
  88. package/lib/auth/serializer/src/fast_parser.js +0 -57
  89. package/lib/auth/serializer/src/number_utils.js +0 -43
  90. package/lib/auth/serializer/src/object_id.js +0 -43
  91. package/lib/auth/serializer/src/operations.js +0 -695
  92. package/lib/auth/serializer/src/precision.js +0 -77
  93. package/lib/auth/serializer/src/serializer.js +0 -165
  94. package/lib/auth/serializer/src/template.js +0 -22
  95. package/lib/auth/serializer/src/types.js +0 -1085
  96. package/lib/auth/serializer/src/validation.js +0 -300
  97. package/lib/broadcast/helpers.js +0 -140
  98. package/lib/broadcast/index.js +0 -106
  99. package/lib/broadcast/operations.js +0 -255
  100. package/lib/browser.js +0 -25
  101. package/lib/config.js +0 -23
  102. package/lib/formatter.js +0 -163
  103. package/lib/index.js +0 -21
  104. package/lib/utils.js +0 -50
  105. package/node-18.dockerfile +0 -28
  106. package/test/Crypto.js +0 -100
  107. package/test/KeyFormats.js +0 -105
  108. package/test/all_types.js +0 -115
  109. package/test/api.test.js +0 -363
  110. package/test/broadcast.test.js +0 -231
  111. package/test/browser/BrowserTests.js +0 -55
  112. package/test/comment.test.js +0 -83
  113. package/test/hf20-accounts.test.js +0 -76
  114. package/test/hf21-sps.test.js +0 -78
  115. package/test/memo.test.js +0 -37
  116. package/test/number_utils.js +0 -28
  117. package/test/operations_test.js +0 -39
  118. package/test/promise-broadcast.test.js +0 -86
  119. package/test/reputation.test.js +0 -68
  120. package/test/smt.test.js +0 -347
  121. package/test/test-post.json +0 -13
  122. package/test/test.html +0 -13
  123. package/test/test_helper.js +0 -19
  124. package/test/types_test.js +0 -139
  125. package/test-github-workflow.bat +0 -19
  126. package/test-github-workflow.sh +0 -15
  127. package/webpack/makeConfig.js +0 -113
  128. package/webpack.config.js +0 -2
@@ -0,0 +1,11 @@
1
+ import { PrivateKey } from '../auth/ecc/src/key_private';
2
+ import { PublicKey } from '../auth/ecc/src/key_public';
3
+ export interface MemoData {
4
+ from: string;
5
+ to: string;
6
+ nonce: string;
7
+ check: number;
8
+ encrypted: string;
9
+ }
10
+ export declare function encode(private_key: string | PrivateKey | null, public_key: string | PublicKey | null, memo: string, testNonce?: string): string;
11
+ export declare function decode(private_key: string | PrivateKey | null, memo: string): string;
@@ -0,0 +1,44 @@
1
+ export interface TransferOperation {
2
+ 0: 'transfer';
3
+ 1: {
4
+ from: string;
5
+ to: string;
6
+ amount: string;
7
+ memo: string;
8
+ };
9
+ }
10
+ export interface VoteOperation {
11
+ 0: 'vote';
12
+ 1: {
13
+ voter: string;
14
+ author: string;
15
+ permlink: string;
16
+ weight: number;
17
+ };
18
+ }
19
+ export interface CommentOperation {
20
+ 0: 'comment';
21
+ 1: {
22
+ parent_author: string;
23
+ parent_permlink: string;
24
+ author: string;
25
+ permlink: string;
26
+ title: string;
27
+ body: string;
28
+ json_metadata: string;
29
+ };
30
+ }
31
+ export interface CustomJsonOperation {
32
+ 0: 'custom_json';
33
+ 1: {
34
+ required_auths: string[];
35
+ required_posting_auths: string[];
36
+ id: string;
37
+ json: string;
38
+ };
39
+ }
40
+ export type Operation = TransferOperation | VoteOperation | CommentOperation | CustomJsonOperation;
41
+ export declare const createTransfer: (from: string, to: string, amount: string, memo?: string) => TransferOperation;
42
+ export declare const createVote: (voter: string, author: string, permlink: string, weight: number) => VoteOperation;
43
+ export declare const createComment: (parentAuthor: string, parentPermlink: string, author: string, permlink: string, title: string, body: string, jsonMetadata?: string) => CommentOperation;
44
+ export declare const createCustomJson: (requiredAuths: string[], requiredPostingAuths: string[], id: string, json: string) => CustomJsonOperation;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Convert implementation to support serializing types.
3
+ */
4
+ export declare class Convert {
5
+ private type;
6
+ constructor(type: any);
7
+ toHex(value: any): string;
8
+ fromHex(hex: string): any;
9
+ fromObject(obj: any): any;
10
+ toObject(obj: any): any;
11
+ }
12
+ export default function (type: any): Convert;
@@ -0,0 +1,11 @@
1
+ import type { Operation, Transaction } from '../types';
2
+ export declare const serializeTransaction: (transaction: Transaction) => Buffer;
3
+ export declare const serializeOperation: (operation: Operation) => Buffer;
4
+ export declare const getTransactionDigest: (transaction: Transaction) => Buffer;
5
+ export declare const getTransactionId: (transaction: Transaction) => string;
6
+ export declare const serialize: (operation: any) => Buffer;
7
+ export declare const deserialize: (buffer: Buffer) => any;
8
+ export declare const deserializeTransaction: (buffer: Buffer) => any;
9
+ export { default as convert } from './convert';
10
+ export * as types from './types';
11
+ export * as precision from './precision';
@@ -0,0 +1,8 @@
1
+ /**
2
+ Convert 12.34 with a precision of 3 into 12340
3
+ @arg {number|string} number - Use strings for large numbers. This may contain one decimal but no sign
4
+ @arg {number} precision - number of implied decimal places (usually causes right zero padding)
5
+ @return {string} -
6
+ */
7
+ export declare function toImpliedDecimal(number: number | string, precision: number): string;
8
+ export declare function fromImpliedDecimal(number: number | string, precision: number): string;
@@ -0,0 +1,5 @@
1
+ export declare const _internal: {
2
+ decimal_precision_string: (number: string, precision: number) => string;
3
+ };
4
+ export declare const to_bigint64: (number_or_string: string, precision: number) => bigint;
5
+ export declare const to_string64: (input: any, precision: number) => string;
@@ -0,0 +1,36 @@
1
+ export declare const vote_id: {
2
+ fromObject: (id: string) => string;
3
+ toHex: (id: string) => string;
4
+ };
5
+ export declare const set: (_type: any) => {
6
+ fromObject: (arr: any[]) => any[];
7
+ toObject: (set: any[]) => any[];
8
+ toHex: (arr: any[]) => string;
9
+ };
10
+ export declare const map: (_keyType: any, _valueType: any) => {
11
+ fromObject: (arr: [any, any][]) => [any, any][];
12
+ toObject: (map: [any, any][]) => [any, any][];
13
+ toHex: (arr: [any, any][]) => string;
14
+ };
15
+ export declare const bool: {
16
+ toHex: (value: boolean) => string;
17
+ };
18
+ export declare const string: {
19
+ toHex: (value: string) => string;
20
+ };
21
+ export declare const public_key: {
22
+ toHex: (key: string) => string;
23
+ };
24
+ export declare const uint16: {
25
+ toHex: (value: number) => string;
26
+ };
27
+ export declare const _internal: {
28
+ decimal_precision_string: (value: string, precision: number) => string;
29
+ precision_number_long: (value: string, precision: number) => void;
30
+ };
31
+ export declare const type_id: {
32
+ toHex: (value: string) => string;
33
+ };
34
+ export declare const protocol_id_type: (_name: string) => {
35
+ toHex: (value: number) => string;
36
+ };
@@ -0,0 +1,131 @@
1
+ export interface SteemConfig {
2
+ addressPrefix: string;
3
+ chainId: string;
4
+ node?: string;
5
+ nodes?: string[];
6
+ }
7
+ export interface Account {
8
+ id: number;
9
+ name: string;
10
+ owner: Authority;
11
+ active: Authority;
12
+ posting: Authority;
13
+ memo_key: string;
14
+ json_metadata: string;
15
+ proxy: string;
16
+ last_owner_update: string;
17
+ last_account_update: string;
18
+ created: string;
19
+ mined: boolean;
20
+ recovery_account: string;
21
+ reset_account: string;
22
+ last_account_recovery: string;
23
+ comment_count: number;
24
+ lifetime_vote_count: number;
25
+ post_count: number;
26
+ can_vote: boolean;
27
+ voting_power: number;
28
+ last_vote_time: string;
29
+ balance: string;
30
+ savings_balance: string;
31
+ sbd_balance: string;
32
+ sbd_seconds: string;
33
+ sbd_seconds_last_update: string;
34
+ sbd_last_interest_payment: string;
35
+ savings_sbd_balance: string;
36
+ savings_sbd_seconds: string;
37
+ savings_sbd_seconds_last_update: string;
38
+ savings_sbd_last_interest_payment: string;
39
+ savings_withdraw_requests: number;
40
+ reward_sbd_balance: string;
41
+ reward_steem_balance: string;
42
+ reward_vesting_balance: string;
43
+ reward_vesting_steem: string;
44
+ vesting_shares: string;
45
+ delegated_vesting_shares: string;
46
+ received_vesting_shares: string;
47
+ vesting_withdraw_rate: string;
48
+ next_vesting_withdrawal: string;
49
+ withdrawn: string;
50
+ to_withdraw: string;
51
+ withdraw_routes: number;
52
+ curation_rewards: string;
53
+ posting_rewards: string;
54
+ proxied_vsf_votes: number[];
55
+ witnesses_produced: number;
56
+ last_post: string;
57
+ last_root_post: string;
58
+ average_bandwidth: string;
59
+ lifetime_bandwidth: string;
60
+ last_bandwidth_update: string;
61
+ average_market_bandwidth: string;
62
+ lifetime_market_bandwidth: string;
63
+ last_market_bandwidth_update: string;
64
+ vesting_balance: string;
65
+ reputation: string;
66
+ transfer_history: any[];
67
+ market_history: any[];
68
+ post_history: any[];
69
+ vote_history: any[];
70
+ other_history: any[];
71
+ witness_votes: string[];
72
+ tags_usage: any[];
73
+ guest_bloggers: any[];
74
+ blog_category: any;
75
+ }
76
+ export interface Authority {
77
+ weight_threshold: number;
78
+ account_auths: [string, number][];
79
+ key_auths: [string, number][];
80
+ }
81
+ export interface Transaction {
82
+ ref_block_num: number;
83
+ ref_block_prefix: number;
84
+ expiration: string;
85
+ operations: Operation[];
86
+ extensions: any[];
87
+ signatures?: string[];
88
+ }
89
+ export interface SignedTransaction extends Transaction {
90
+ signatures: string[];
91
+ }
92
+ export interface TransferOperation {
93
+ 0: 'transfer';
94
+ 1: {
95
+ from: string;
96
+ to: string;
97
+ amount: string;
98
+ memo: string;
99
+ };
100
+ }
101
+ export interface VoteOperation {
102
+ 0: 'vote';
103
+ 1: {
104
+ voter: string;
105
+ author: string;
106
+ permlink: string;
107
+ weight: number;
108
+ };
109
+ }
110
+ export interface CommentOperation {
111
+ 0: 'comment';
112
+ 1: {
113
+ parent_author: string;
114
+ parent_permlink: string;
115
+ author: string;
116
+ permlink: string;
117
+ title: string;
118
+ body: string;
119
+ json_metadata: string;
120
+ };
121
+ }
122
+ export interface CustomJsonOperation {
123
+ 0: 'custom_json';
124
+ 1: {
125
+ required_auths: string[];
126
+ required_posting_auths: string[];
127
+ id: string;
128
+ json: string;
129
+ };
130
+ }
131
+ export type Operation = TransferOperation | VoteOperation | CommentOperation | CustomJsonOperation;
@@ -0,0 +1,34 @@
1
+ export interface SteemConfig {
2
+ addressPrefix: string;
3
+ chainId: string;
4
+ node: string;
5
+ nodes: string[];
6
+ uri?: string;
7
+ /**
8
+ * WebSocket URL
9
+ * NOTE: WebSocket functionality is currently not supported.
10
+ * This field is kept for backward compatibility only.
11
+ * Please use HTTP transport (via node or uri field) for API calls.
12
+ */
13
+ websocket?: string;
14
+ }
15
+ export interface Account {
16
+ name: string;
17
+ }
18
+ export interface Authority {
19
+ weight_threshold: number;
20
+ account_auths: [string, number][];
21
+ key_auths: [string, number][];
22
+ }
23
+ export interface Operation {
24
+ type: string;
25
+ value: any;
26
+ }
27
+ export interface Transaction {
28
+ ref_block_num: number;
29
+ ref_block_prefix: number;
30
+ expiration: string;
31
+ operations: Operation[];
32
+ extensions: any[];
33
+ signatures?: string[];
34
+ }
@@ -0,0 +1,36 @@
1
+ /**
2
+ * Debug utility for controlled debug output
3
+ * Can be enabled via:
4
+ * 1. Config: steem.config.set({ debug: true })
5
+ * 2. Environment variable: DEBUG=steem-js or DEBUG=steem-js:*
6
+ * 3. Specific debug flags: DEBUG=steem-js:transaction,steem-js:signature
7
+ */
8
+ export declare const debug: {
9
+ /**
10
+ * Log debug information
11
+ * @param flag - Optional debug flag (e.g., 'transaction', 'signature')
12
+ * @param args - Arguments to log
13
+ */
14
+ log(flag?: string, ...args: any[]): void;
15
+ /**
16
+ * Log transaction debug info
17
+ */
18
+ transaction(...args: any[]): void;
19
+ /**
20
+ * Log signature debug info
21
+ */
22
+ signature(...args: any[]): void;
23
+ /**
24
+ * Log warning (always shown, but can be controlled)
25
+ */
26
+ warn(...args: any[]): void;
27
+ /**
28
+ * Log error (always shown)
29
+ */
30
+ error(...args: any[]): void;
31
+ /**
32
+ * Check if debug is enabled for a specific flag
33
+ */
34
+ isEnabled(flag?: string): boolean;
35
+ };
36
+ export default debug;
@@ -0,0 +1,9 @@
1
+ export declare const sleep: (ms: number) => Promise<void>;
2
+ export declare const retry: <T>(fn: () => Promise<T>, retries?: number, delay?: number) => Promise<T>;
3
+ export declare const chunk: <T>(array: T[], size: number) => T[][];
4
+ export declare const unique: <T>(array: T[]) => T[];
5
+ export declare const flatten: <T>(array: T[][]) => T[];
6
+ export declare const isValidAddress: (address: string) => boolean;
7
+ export declare const isValidAmount: (amount: string) => boolean;
8
+ export declare const isValidPermlink: (permlink: string) => boolean;
9
+ export { debug } from './debug';
@@ -0,0 +1,2 @@
1
+ export * from './utils/index';
2
+ export declare const camelCase: (str: string) => string;
package/package.json CHANGED
@@ -1,104 +1,85 @@
1
1
  {
2
2
  "name": "@steemit/steem-js",
3
- "version": "0.8.0",
4
- "description": "JavaScript library for the Steem blockchain",
5
- "main": "lib/index.js",
6
- "scripts": {
7
- "build": "npm run build-browser && npm run build-node",
8
- "build-browser": "cross-env NODE_ENV=production rimraf dist && webpack",
9
- "build-node": "babel src --out-dir lib --plugins=@babel/plugin-transform-modules-commonjs",
10
- "prepare": "npm run build",
11
- "test": "babel-node --presets @babel/preset-env node_modules/mocha/bin/mocha test/*.js",
12
- "test-auth": "npm test -- --grep 'steem.auth'",
13
- "lint": "eslint src",
14
- "prepublish": "npm run build"
15
- },
16
- "browser": {
17
- "ws": false,
18
- "crypto": false
19
- },
20
- "repository": {
21
- "type": "git",
22
- "url": "git+https://github.com/steemit/steem-js.git"
3
+ "version": "1.0.1",
4
+ "description": "Steem blockchain JavaScript/TypeScript library",
5
+ "type": "module",
6
+ "main": "dist/index.cjs",
7
+ "module": "dist/index.js",
8
+ "browser": "dist/index.umd.js",
9
+ "types": "dist/index.d.ts",
10
+ "exports": {
11
+ ".": {
12
+ "types": "./dist/index.d.ts",
13
+ "import": "./dist/index.js",
14
+ "require": "./dist/index.cjs",
15
+ "browser": "./dist/index.umd.js"
16
+ }
23
17
  },
18
+ "files": [
19
+ "dist"
20
+ ],
21
+ "unpkg": "dist/index.umd.js",
22
+ "jsdelivr": "dist/index.umd.js",
24
23
  "keywords": [
25
24
  "steem",
26
- "steemit",
27
25
  "blockchain",
28
- "steemjs"
26
+ "cryptocurrency"
29
27
  ],
30
- "author": "Fabien (https://github.com/bonustrack)",
28
+ "author": "hightouch",
31
29
  "license": "MIT",
32
- "bugs": {
33
- "url": "https://github.com/steemit/steem-js/issues"
30
+ "devDependencies": {
31
+ "@rollup/plugin-alias": "^6.0.0",
32
+ "@rollup/plugin-commonjs": "^25.0.7",
33
+ "@rollup/plugin-json": "^6.1.0",
34
+ "@rollup/plugin-node-resolve": "^15.2.3",
35
+ "@rollup/plugin-typescript": "^11.1.6",
36
+ "@types/bigi": "^1.4.5",
37
+ "@types/bluebird": "^3.5.42",
38
+ "@types/bytebuffer": "^5.0.49",
39
+ "@types/debug": "^4.1.12",
40
+ "@types/ecurve": "^1.0.3",
41
+ "@types/lodash": "^4.17.18",
42
+ "@types/node": "^20.11.24",
43
+ "@types/ws": "^8.18.1",
44
+ "@typescript-eslint/eslint-plugin": "^7.1.0",
45
+ "@typescript-eslint/parser": "^7.1.0",
46
+ "@vitest/coverage-v8": "^3.1.3",
47
+ "assert": "^2.1.0",
48
+ "buffer": "^6.0.3",
49
+ "crypto-browserify": "^3.12.1",
50
+ "eslint": "^8.57.0",
51
+ "events": "^3.3.0",
52
+ "prettier": "^3.2.5",
53
+ "rollup": "^4.12.0",
54
+ "stream-browserify": "^3.0.0",
55
+ "tslib": "^2.6.2",
56
+ "typescript": "^5.3.3",
57
+ "util": "^0.12.5",
58
+ "vitest": "^3.1.3"
34
59
  },
35
- "homepage": "https://github.com/steemit/steem-js#readme",
36
60
  "dependencies": {
37
- "assert": "^1.5.0",
38
- "babel-polyfill": "^6.26.0",
61
+ "axios": "^1.6.7",
39
62
  "bigi": "^1.4.2",
40
63
  "bluebird": "^3.7.2",
41
- "browserify-aes": "^1.2.0",
42
- "bs58": "^4.0.1",
64
+ "bs58": "^6.0.0",
43
65
  "bytebuffer": "^5.0.1",
44
66
  "create-hash": "^1.2.0",
45
67
  "create-hmac": "^1.1.7",
46
- "cross-fetch": "^3.0.6",
47
- "detect-node": "^2.0.4",
68
+ "crypto-js": "^4.2.0",
48
69
  "ecurve": "^1.0.6",
49
- "https-browserify": "^1.0.0",
50
- "is-hex": "^1.1.3",
51
- "isomorphic-ws": "^4.0.1",
52
- "lodash": "^4.17.15",
53
- "noble-secp256k1": "^1.0.3",
54
- "os-browserify": "^0.3.0",
55
- "path-browserify": "^1.0.1",
56
- "randombytes": "^2.1.0",
57
- "retry": "^0.12.0",
58
- "ripemd160": "^2.0.2",
59
- "safe-buffer": "^5.2.1",
60
- "secp256k1": "^3.8.0",
61
- "secure-random": "^1.1.2",
62
- "should": "^13.2.3",
63
- "stream-browserify": "^2.0.2",
64
- "stream-http": "^3.1.1",
65
- "util": "^0.12.3",
66
- "ws": "^7.4.6"
70
+ "lodash": "^4.17.21",
71
+ "long": "^5.2.3",
72
+ "retry": "^0.13.1",
73
+ "ws": "^8.18.2"
67
74
  },
68
- "devDependencies": {
69
- "@babel/cli": "^7.8.4",
70
- "@babel/core": "^7.9.6",
71
- "@babel/node": "^7.26.0",
72
- "@babel/plugin-transform-modules-commonjs": "^7.9.6",
73
- "@babel/preset-env": "^7.9.6",
74
- "@babel/register": "^7.9.0",
75
- "ajv": "^6.12.2",
76
- "ajv-keywords": "^3.4.1",
77
- "babel-loader": "^8.1.0",
78
- "braces": "^3.0.3",
79
- "buffer": "^5.6.0",
80
- "core-js": "^2.6.11",
81
- "cross-env": "^7.0.2",
82
- "crypto-browserify": "^3.12.0",
83
- "eslint": "^6.8.0",
84
- "mocha": "^10.2.0",
85
- "process": "^0.11.10",
86
- "rimraf": "^2.7.1",
87
- "webpack": "^4.43.0",
88
- "webpack-cli": "^3.3.11",
89
- "webpack-visualizer-plugin": "^0.1.11"
90
- },
91
- "resolutions": {
92
- "json5": "^1.0.2",
93
- "braces": "^3.0.3",
94
- "micromatch": "^4.0.5",
95
- "glob-parent": "^5.1.2"
96
- },
97
- "contributors": [
98
- "Hightouch (https://github.com/hightouch67)",
99
- "Fabien (https://github.com/bonustrack)",
100
- "James Calfee (https://github.com/jcalfee)",
101
- "Nilesh Suthar (https://github.com/nil1511)",
102
- "Pedro Tacla Yamada (https://github.com/yamadapc)"
103
- ]
104
- }
75
+ "scripts": {
76
+ "build": "rollup -c",
77
+ "dev": "rollup -c -w",
78
+ "test": "vitest run",
79
+ "test:watch": "vitest watch",
80
+ "test:coverage": "vitest run --coverage",
81
+ "typecheck": "tsc --noEmit",
82
+ "lint": "eslint src --ext .ts",
83
+ "format": "prettier --write \"src/**/*.ts\""
84
+ }
85
+ }
package/.dockerignore DELETED
@@ -1,12 +0,0 @@
1
- .idea
2
- .save
3
- logs
4
- *.log
5
- npm-debug.log*
6
- build/Release
7
- node_modules
8
- .tern-port
9
- dist/steem-tests.min.js*
10
- .tern-port
11
- .envrc
12
- dist
package/.editorconfig DELETED
@@ -1,20 +0,0 @@
1
- # EditorConfig helps developers define and maintain consistent
2
- # coding styles between different editors and IDEs
3
- # editorconfig.org
4
-
5
- root = true
6
-
7
- [*]
8
-
9
- # Change these settings to your own preference
10
- indent_style = space
11
- indent_size = 2
12
-
13
- # We recommend you to keep these unchanged
14
- end_of_line = lf
15
- charset = utf-8
16
- trim_trailing_whitespace = true
17
- insert_final_newline = true
18
-
19
- [*.md]
20
- trim_trailing_whitespace = false
package/.eslintrc DELETED
@@ -1,27 +0,0 @@
1
- {
2
- "parser": "babel-eslint",
3
- "parserOptions": {
4
- "ecmaVersion": 7,
5
- "sourceType": "module"
6
- },
7
- "env": {
8
- "es6": true,
9
- "node": true,
10
- "browser": true,
11
- "mocha": true,
12
- },
13
- "rules": {
14
- "no-undef": ["error"],
15
- "no-const-assign": ["error"],
16
- "no-this-before-super": ["error"],
17
- "use-isnan": ["error"],
18
-
19
- "prefer-const": ["warn"],
20
- "no-var": ["warn"],
21
- "no-unused-vars": ["warn"],
22
- "no-unreachable": ["warn"],
23
- "no-shadow": ["warn"],
24
- "no-constant-condition": ["warn"],
25
- "no-shadow-restricted-names": ["off"], # warn misfired on 'import' statements
26
- },
27
- }
package/LICENSE DELETED
@@ -1,21 +0,0 @@
1
- MIT License
2
-
3
- Copyright (c) 2017 Steem.js
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
package/circle.yml DELETED
@@ -1,3 +0,0 @@
1
- machine:
2
- node:
3
- version: 18
package/config.json DELETED
@@ -1,10 +0,0 @@
1
- {
2
- "transport": "http",
3
- "websocket": "wss://api.steemit.com",
4
- "uri": "https://api.steemit.com",
5
- "url": "",
6
- "dev_uri": "https://api.steemitdev.com",
7
- "stage_uri": "https://api.steemitstage.com",
8
- "address_prefix": "STM",
9
- "chain_id": "0000000000000000000000000000000000000000000000000000000000000000"
10
- }