mirror of
https://github.com/lightpanda-io/browser.git
synced 2026-06-11 09:35:59 -04:00
Merge pull request #2487 from navidemad/feat/external-stylesheets-flag
Add --enable-external-stylesheets flag with fetch + parse
This commit is contained in:
@@ -100,6 +100,7 @@ const CommonOptions = .{
|
||||
.{ .name = "storage_sqlite_path", .type = ?[:0]const u8 },
|
||||
.{ .name = "disable_subframes", .type = bool },
|
||||
.{ .name = "disable_workers", .type = bool },
|
||||
.{ .name = "enable_external_stylesheets", .type = bool },
|
||||
};
|
||||
|
||||
fn dumpValidator(_: Allocator, args: *std.process.ArgIterator) !?DumpFormat {
|
||||
@@ -255,6 +256,13 @@ pub fn disableWorkers(self: *const Config) bool {
|
||||
};
|
||||
}
|
||||
|
||||
pub fn enableExternalStylesheets(self: *const Config) bool {
|
||||
return switch (self.mode) {
|
||||
inline .serve, .fetch, .mcp => |opts| opts.enable_external_stylesheets,
|
||||
else => unreachable,
|
||||
};
|
||||
}
|
||||
|
||||
pub fn httpProxy(self: *const Config) ?[:0]const u8 {
|
||||
return switch (self.mode) {
|
||||
inline .serve, .fetch, .mcp => |opts| opts.http_proxy,
|
||||
|
||||
Reference in New Issue
Block a user