浏览代码

inroduce idl account getter (#2367)

Andrey Frolov 2 年之前
父节点
当前提交
79a066661c
共有 1 个文件被更改,包括 6 次插入0 次删除
  1. 6 0
      ts/packages/anchor/src/program/namespace/account.ts

+ 6 - 0
ts/packages/anchor/src/program/namespace/account.ts

@@ -110,6 +110,12 @@ export class AccountClient<
   }
   private _coder: Coder;
 
+  /**
+   * Returns the idl account.
+   */
+  get idlAccount(): A {
+    return this._idlAccount;
+  }
   private _idlAccount: A;
 
   constructor(