Remove remaining Node imports from core
Summary: Removed remaining path / fs imports from Flipper core. `expand-tide` needed replacement too, but noticed that it never actually rewrites paths since all use cases were already using absolute paths, so removed it instead. Reviewed By: aigoncharov Differential Revision: D33017654 fbshipit-source-id: e12f66ef68b5f9e4279411c94445a2fb87249e9a
This commit is contained in:
committed by
Facebook GitHub Bot
parent
d95b15094f
commit
accef856fc
@@ -11,7 +11,6 @@ import path from 'path';
|
||||
import {homedir} from 'os';
|
||||
import fs from 'fs-extra';
|
||||
import pFilter from 'p-filter';
|
||||
import expandTilde from 'expand-tilde';
|
||||
|
||||
const flipperDataDir = path.join(homedir(), '.flipper');
|
||||
|
||||
@@ -44,7 +43,7 @@ export async function getPluginSourceFolders(): Promise<string[]> {
|
||||
}
|
||||
pluginFolders.push(path.resolve(__dirname, '..', '..', 'plugins', 'public'));
|
||||
pluginFolders.push(path.resolve(__dirname, '..', '..', 'plugins', 'fb'));
|
||||
return pFilter(pluginFolders.map(expandTilde), (p) => fs.pathExists(p));
|
||||
return pFilter(pluginFolders, (p) => fs.pathExists(p));
|
||||
}
|
||||
|
||||
export function getPluginInstallationDir(name: string) {
|
||||
|
||||
Reference in New Issue
Block a user