@solana/rpc-graphql 2.0.0-experimental.f8c941c → 2.0.0-experimental.fbbf6ba
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.
- package/dist/index.browser.cjs +5 -6
- package/dist/index.browser.cjs.map +1 -1
- package/dist/index.browser.js +5 -6
- package/dist/index.browser.js.map +1 -1
- package/dist/index.native.js +5 -6
- package/dist/index.native.js.map +1 -1
- package/dist/index.node.cjs +5 -6
- package/dist/index.node.cjs.map +1 -1
- package/dist/index.node.js +5 -6
- package/dist/index.node.js.map +1 -1
- package/dist/types/context.d.ts +0 -1
- package/dist/types/context.d.ts.map +1 -1
- package/dist/types/index.d.ts +1 -2
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/loaders/account.d.ts +1 -2
- package/dist/types/loaders/account.d.ts.map +1 -1
- package/dist/types/loaders/block.d.ts +1 -2
- package/dist/types/loaders/block.d.ts.map +1 -1
- package/dist/types/loaders/loader.d.ts +4 -4
- package/dist/types/loaders/loader.d.ts.map +1 -1
- package/dist/types/loaders/program-accounts.d.ts +1 -2
- package/dist/types/loaders/program-accounts.d.ts.map +1 -1
- package/dist/types/loaders/transaction.d.ts +1 -2
- package/dist/types/loaders/transaction.d.ts.map +1 -1
- package/package.json +9 -37
package/dist/index.native.js
CHANGED
|
@@ -65,7 +65,7 @@ function applyDefaultArgs2({
|
|
|
65
65
|
async function loadBlock(rpc, { slot, ...config }) {
|
|
66
66
|
return await rpc.getBlock(
|
|
67
67
|
slot,
|
|
68
|
-
// @ts-expect-error FIX ME: https://github.com/
|
|
68
|
+
// @ts-expect-error FIX ME: https://github.com/microsoft/TypeScript/issues/43187
|
|
69
69
|
config
|
|
70
70
|
).send();
|
|
71
71
|
}
|
|
@@ -101,7 +101,7 @@ function applyDefaultArgs3({
|
|
|
101
101
|
async function loadProgramAccounts(rpc, { programAddress, ...config }) {
|
|
102
102
|
return await rpc.getProgramAccounts(
|
|
103
103
|
programAddress,
|
|
104
|
-
// @ts-expect-error FIX ME: https://github.com/
|
|
104
|
+
// @ts-expect-error FIX ME: https://github.com/microsoft/TypeScript/issues/43187
|
|
105
105
|
config
|
|
106
106
|
).send();
|
|
107
107
|
}
|
|
@@ -133,7 +133,7 @@ function applyDefaultArgs4({
|
|
|
133
133
|
async function loadTransaction(rpc, { signature, ...config }) {
|
|
134
134
|
return await rpc.getTransaction(
|
|
135
135
|
signature,
|
|
136
|
-
// @ts-expect-error FIX ME: https://github.com/
|
|
136
|
+
// @ts-expect-error FIX ME: https://github.com/microsoft/TypeScript/issues/43187
|
|
137
137
|
config
|
|
138
138
|
).send();
|
|
139
139
|
}
|
|
@@ -160,8 +160,7 @@ function createSolanaGraphQLContext(rpc) {
|
|
|
160
160
|
block: createBlockLoader(rpc),
|
|
161
161
|
programAccounts: createProgramAccountsLoader(rpc),
|
|
162
162
|
transaction: createTransactionLoader(rpc)
|
|
163
|
-
}
|
|
164
|
-
rpc
|
|
163
|
+
}
|
|
165
164
|
};
|
|
166
165
|
}
|
|
167
166
|
|
|
@@ -2894,13 +2893,13 @@ function createSolanaGraphQLTypeDefs() {
|
|
|
2894
2893
|
|
|
2895
2894
|
// src/index.ts
|
|
2896
2895
|
function createRpcGraphQL(rpc) {
|
|
2897
|
-
const contextValue = createSolanaGraphQLContext(rpc);
|
|
2898
2896
|
const schema = makeExecutableSchema({
|
|
2899
2897
|
resolvers: createSolanaGraphQLResolvers(),
|
|
2900
2898
|
typeDefs: createSolanaGraphQLTypeDefs()
|
|
2901
2899
|
});
|
|
2902
2900
|
return {
|
|
2903
2901
|
async query(source, variableValues) {
|
|
2902
|
+
const contextValue = createSolanaGraphQLContext(rpc);
|
|
2904
2903
|
return graphql({
|
|
2905
2904
|
contextValue,
|
|
2906
2905
|
schema,
|