> ## Documentation Index
> Fetch the complete documentation index at: https://docs.supernote.com/llms.txt
> Use this file to discover all available pages before exploring further.

# getPluginDirPath

> 获取插件安装目录路径。

```ts theme={null}
getPluginDirPath(): Promise<string | null | undefined>;
```

**返回**

* `Promise<string | null | undefined>`：插件安装目录路径

## 示例

```ts wrap theme={null}
import { PluginManager } from 'sn-plugin-lib';

/**
 * 获取插件目录路径的示例。
 */
export async function exampleGetPluginDirPath() {
  const dir = await PluginManager.getPluginDirPath();
  return dir;
}
```
