mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-22 08:00:45 +00:00
LibJS: Implement console.dirxml
This function actually gets tested in WPT.
This commit is contained in:
parent
ad06ac0d58
commit
08284e0ef6
Notes:
github-actions[bot]
2025-08-17 11:29:56 +00:00
Author: https://github.com/tete17
Commit: 08284e0ef6
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5861
Reviewed-by: https://github.com/trflynn89
5 changed files with 40 additions and 1 deletions
|
@ -49,6 +49,7 @@ void ConsoleObject::initialize(Realm& realm)
|
|||
define_native_function(realm, vm.names.trace, trace, 0, attr);
|
||||
define_native_function(realm, vm.names.warn, warn, 0, attr);
|
||||
define_native_function(realm, vm.names.dir, dir, 0, attr);
|
||||
define_native_function(realm, vm.names.dirxml, dir, 0, attr);
|
||||
define_native_function(realm, vm.names.count, count, 0, attr);
|
||||
define_native_function(realm, vm.names.countReset, count_reset, 0, attr);
|
||||
define_native_function(realm, vm.names.group, group, 0, attr);
|
||||
|
@ -131,6 +132,13 @@ JS_DEFINE_NATIVE_FUNCTION(ConsoleObject::dir)
|
|||
return console_object.console().dir();
|
||||
}
|
||||
|
||||
// 1.1.11 dirxml(...data) https://console.spec.whatwg.org/#dirxml
|
||||
JS_DEFINE_NATIVE_FUNCTION(ConsoleObject::dirxml)
|
||||
{
|
||||
auto& console_object = *vm.current_realm()->intrinsics().console_object();
|
||||
return console_object.console().dirxml();
|
||||
}
|
||||
|
||||
// 1.2.1. count(label), https://console.spec.whatwg.org/#count
|
||||
JS_DEFINE_NATIVE_FUNCTION(ConsoleObject::count)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue