mirror of
https://github.com/lightpanda-io/browser.git
synced 2025-10-30 07:31:47 +00:00
initialize ICU
This makes functions like new Intl.DateTimeFormat() not crash.
This commit is contained in:
@@ -34,7 +34,10 @@ const SCOPE_ARENA_RETAIN = 1024 * 64;
|
||||
pub const Platform = struct {
|
||||
inner: v8.Platform,
|
||||
|
||||
pub fn init() Platform {
|
||||
pub fn init() !Platform {
|
||||
if (v8.initV8ICU() == false) {
|
||||
return error.FailedToInitializeICU;
|
||||
}
|
||||
const platform = v8.Platform.initDefault(0, true);
|
||||
v8.initV8Platform(platform);
|
||||
v8.initV8();
|
||||
|
||||
Reference in New Issue
Block a user