Skip to content

Commit 78c5ff4

Browse files
committed
chore: add TypeScript definitions for BigInt
1 parent 131ad32 commit 78c5ff4

2 files changed

Lines changed: 37 additions & 1 deletion

File tree

BufferList.d.ts

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,42 @@ interface BufferList {
205205

206206
readFloatLE: Buffer['readFloatLE'];
207207

208+
/**
209+
* All of the standard byte-reading methods of the Buffer interface are implemented and will operate across internal Buffer boundaries transparently.
210+
* See the [Buffer](http://nodejs.org/docs/latest/api/buffer.html) documentation for how these work.
211+
*
212+
* @param offset
213+
*/
214+
215+
readBigInt64BE: Buffer['readBigInt64BE'];
216+
217+
/**
218+
* All of the standard byte-reading methods of the Buffer interface are implemented and will operate across internal Buffer boundaries transparently.
219+
* See the [Buffer](http://nodejs.org/docs/latest/api/buffer.html) documentation for how these work.
220+
*
221+
* @param offset
222+
*/
223+
224+
readBigInt64LE: Buffer['readBigInt64LE'];
225+
226+
/**
227+
* All of the standard byte-reading methods of the Buffer interface are implemented and will operate across internal Buffer boundaries transparently.
228+
* See the [Buffer](http://nodejs.org/docs/latest/api/buffer.html) documentation for how these work.
229+
*
230+
* @param offset
231+
*/
232+
233+
readBigUInt64BE: Buffer['readBigUInt64BE'];
234+
235+
/**
236+
* All of the standard byte-reading methods of the Buffer interface are implemented and will operate across internal Buffer boundaries transparently.
237+
* See the [Buffer](http://nodejs.org/docs/latest/api/buffer.html) documentation for how these work.
238+
*
239+
* @param offset
240+
*/
241+
242+
readBigUInt64LE: Buffer['readBigUInt64LE'];
243+
208244
/**
209245
* All of the standard byte-reading methods of the Buffer interface are implemented and will operate across internal Buffer boundaries transparently.
210246
* See the [Buffer](http://nodejs.org/docs/latest/api/buffer.html) documentation for how these work.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"lint": "standard *.js test/*.js",
99
"test": "npm run lint && npm run test:types && node test/test.js | faucet",
1010
"test:ci": "npm run lint && node test/test.js && npm run test:types",
11-
"test:types": "tsc --allowJs --noEmit test/test.js",
11+
"test:types": "tsc --target esnext --moduleResolution node --allowJs --noEmit test/test.js",
1212
"build": "true"
1313
},
1414
"repository": {

0 commit comments

Comments
 (0)