import { parseSemver } from '@sentry/utils';
/**
 * Parsed Electron version
 */
function version() {
    var version = parseSemver(process.versions.electron);
    return { major: version.major || 0, minor: version.minor || 0, patch: version.patch || 0 };
}
/**
 * Electron >=8.4 | >=9.1 | >=10
 * Use `render-process-gone` rather than `crashed`
 */
export function supportsRenderProcessGone() {
    var _a = version(), major = _a.major, minor = _a.minor;
    return (major === 8 && minor >= 4) || (major === 9 && minor >= 1) || major >= 10;
}
/**
 * Electron < 9 requires `crashReporter.start()` in the renderer
 */
export function requiresNativeHandlerRenderer() {
    var major = version().major;
    return major < 9;
}
/**
 * Electron >= 6 uses crashpad on Windows
 */
export function supportsCrashpadOnWindows() {
    var major = version().major;
    return major >= 6;
}
/**
 * Electron >= 9 supports `app.getPath('crashDumps')` rather than
 * `crashReporter.getCrashesDirectory()`
 */
export function supportsGetPathCrashDumps() {
    var major = version().major;
    return major >= 9;
}
//# sourceMappingURL=electron-version.js.map