Compare commits

..

1 Commits

Author SHA1 Message Date
Elliot Lee
045fc06047 feat: add missing fields to Transaction type
These fields are available when retrieving transactions from a validated ledger,
e.g. with the 'account_tx' command.
2021-10-25 22:12:49 -07:00
3 changed files with 25 additions and 13 deletions

View File

@@ -176,6 +176,18 @@ export interface BaseTransaction {
* account it says it is from.
*/
TxnSignature?: string
/**
* The date/time when this transaction was included in a validated ledger.
*/
date?: number
/**
* An identifying hash value unique to this transaction, as a hex string.
*/
hash?: string
/**
* The sequence number of the ledger that included this transaction.
*/
ledger_index?: number
}
/**

View File

@@ -34,6 +34,12 @@ function webpackForTest(testFileName) {
filename: match[1] + '.js',
},
plugins: [
new webpack.ProvidePlugin({ process: 'process/browser' }),
new webpack.ProvidePlugin({ Buffer: ['buffer', 'Buffer'] }),
new webpack.IgnorePlugin({
resourceRegExp: /^\.\/wordlists\/(?!english)/,
contextRegExp: /bip39\/src$/,
}),
// this is a bit of a hack to prevent 'bn.js' from being installed 6 times
// TODO: any package that is updated to use bn.js 5.x needs to be removed from `bnJsReplaces` above
// https://github.com/webpack/webpack/issues/5593#issuecomment-390356276
@@ -46,12 +52,6 @@ function webpackForTest(testFileName) {
resource.request = 'diffie-hellman/node_modules/bn.js'
}
}),
new webpack.ProvidePlugin({ process: 'process/browser' }),
new webpack.ProvidePlugin({ Buffer: ['buffer', 'Buffer'] }),
new webpack.IgnorePlugin({
resourceRegExp: /^\.\/wordlists\/(?!english)/,
contextRegExp: /bip39\/src$/,
}),
],
module: {
rules: [

View File

@@ -24,6 +24,13 @@ function getDefaultConfiguration() {
filename: `xrpl.default.js`,
},
plugins: [
new webpack.NormalModuleReplacementPlugin(/^ws$/, './WSWrapper'),
new webpack.ProvidePlugin({ process: 'process/browser' }),
new webpack.ProvidePlugin({ Buffer: ['buffer', 'Buffer'] }),
new webpack.IgnorePlugin({
resourceRegExp: /^\.\/wordlists\/(?!english)/,
contextRegExp: /bip39\/src$/,
}),
// this is a bit of a hack to prevent 'bn.js' from being installed 6 times
// TODO: any package that is updated to use bn.js 5.x needs to be removed from `bnJsReplaces` above
// https://github.com/webpack/webpack/issues/5593#issuecomment-390356276
@@ -36,13 +43,6 @@ function getDefaultConfiguration() {
resource.request = 'diffie-hellman/node_modules/bn.js'
}
}),
new webpack.NormalModuleReplacementPlugin(/^ws$/, './WSWrapper'),
new webpack.ProvidePlugin({ process: 'process/browser' }),
new webpack.ProvidePlugin({ Buffer: ['buffer', 'Buffer'] }),
new webpack.IgnorePlugin({
resourceRegExp: /^\.\/wordlists\/(?!english)/,
contextRegExp: /bip39\/src$/,
}),
],
module: {
rules: [],