Import File implementation

Summary: Implementation was missing for the browser. This provides a default implementation.

Reviewed By: aigoncharov

Differential Revision: D48311198

fbshipit-source-id: fd067600f571234e0fbccfb90853b62f175ff8fb
This commit is contained in:
Lorenzo Blasa
2023-08-14 11:33:06 -07:00
committed by Facebook GitHub Bot
parent 2f5f4911e5
commit ff6f98fc0d
12 changed files with 130 additions and 54 deletions

View File

@@ -108,8 +108,8 @@ export async function installPluginFromNpm(name: string) {
}
}
export async function installPluginFromFile(
packagePath: string,
export async function installPluginFromFileOrBuffer(
packagePath: string | Buffer,
): Promise<InstalledPluginDetails> {
const tmpDir = await promisify(tmp.dir)();
try {