serenity/Ladybird/Types.h
Andreas Kling 5f9a905793 Ladybird+LibJS: Add optional logging of *all* JS exceptions
When running with --log-all-js-exceptions, we will print the message
and backtrace for every single JS exception that is thrown, not just
the ones nobody caught.

This can sometimes be very helpful in debugging sites that swallow
important exceptions.
2024-04-16 16:57:06 +02:00

56 lines
1 KiB
C++

/*
* Copyright (c) 2023, Andrew Kaster <akaster@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include <AK/String.h>
namespace Ladybird {
enum class EnableCallgrindProfiling {
No,
Yes
};
enum class EnableGPUPainting {
No,
Yes
};
enum class IsLayoutTestMode {
No,
Yes
};
enum class UseLagomNetworking {
No,
Yes
};
enum class WaitForDebugger {
No,
Yes
};
enum class LogAllJSExceptions {
No,
Yes
};
struct WebContentOptions {
String command_line;
String executable_path;
Vector<ByteString> certificates;
EnableCallgrindProfiling enable_callgrind_profiling { EnableCallgrindProfiling::No };
EnableGPUPainting enable_gpu_painting { EnableGPUPainting::No };
IsLayoutTestMode is_layout_test_mode { IsLayoutTestMode::No };
UseLagomNetworking use_lagom_networking { UseLagomNetworking::No };
WaitForDebugger wait_for_debugger { WaitForDebugger::No };
LogAllJSExceptions log_all_js_exceptions { LogAllJSExceptions::No };
};
}