arc-sdk-test 0.0.2 → 0.0.4

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.
@@ -0,0 +1,28 @@
1
+ import { A as ArcaneSDK } from '../ArcaneSDK-dPZCBtDG.cjs';
2
+ import '@solana/web3.js';
3
+ import '@switchboard-xyz/common';
4
+ import '@coral-xyz/anchor';
5
+ import '@coral-xyz/anchor/dist/cjs/provider';
6
+
7
+ type UseArcaneSdkOptions = {
8
+ rangeApiKey: string;
9
+ };
10
+ /**
11
+ * React hook that builds an {@link ArcaneSDK} from wallet-adapter context.
12
+ *
13
+ * Requires `ConnectionProvider` and `WalletProvider` ancestors.
14
+ *
15
+ * @example
16
+ * ```tsx
17
+ * import { useArcaneSdk } from "arc-sdk-test/react";
18
+ *
19
+ * function MyComponent() {
20
+ * const sdk = useArcaneSdk({ rangeApiKey: import.meta.env.VITE_RANGE_API_KEY });
21
+ * if (!sdk) return null;
22
+ * // ...
23
+ * }
24
+ * ```
25
+ */
26
+ declare function useArcaneSdk(options: UseArcaneSdkOptions): ArcaneSDK | null;
27
+
28
+ export { type UseArcaneSdkOptions, useArcaneSdk };
@@ -0,0 +1,28 @@
1
+ import { A as ArcaneSDK } from '../ArcaneSDK-dPZCBtDG.js';
2
+ import '@solana/web3.js';
3
+ import '@switchboard-xyz/common';
4
+ import '@coral-xyz/anchor';
5
+ import '@coral-xyz/anchor/dist/cjs/provider';
6
+
7
+ type UseArcaneSdkOptions = {
8
+ rangeApiKey: string;
9
+ };
10
+ /**
11
+ * React hook that builds an {@link ArcaneSDK} from wallet-adapter context.
12
+ *
13
+ * Requires `ConnectionProvider` and `WalletProvider` ancestors.
14
+ *
15
+ * @example
16
+ * ```tsx
17
+ * import { useArcaneSdk } from "arc-sdk-test/react";
18
+ *
19
+ * function MyComponent() {
20
+ * const sdk = useArcaneSdk({ rangeApiKey: import.meta.env.VITE_RANGE_API_KEY });
21
+ * if (!sdk) return null;
22
+ * // ...
23
+ * }
24
+ * ```
25
+ */
26
+ declare function useArcaneSdk(options: UseArcaneSdkOptions): ArcaneSDK | null;
27
+
28
+ export { type UseArcaneSdkOptions, useArcaneSdk };