mirror of
https://github.com/tiennm99/ccs.git
synced 2026-10-04 10:13:18 +00:00
10 lines
281 B
TypeScript
10 lines
281 B
TypeScript
export type BrowserPlatformKey = 'darwin' | 'linux' | 'win32';
|
|
|
|
export function getNodePlatformKey(
|
|
platform: NodeJS.Platform = process.platform
|
|
): BrowserPlatformKey {
|
|
if (platform === 'darwin') return 'darwin';
|
|
if (platform === 'win32') return 'win32';
|
|
return 'linux';
|
|
}
|