1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 15:47:44 +00:00

Spreadsheet: Enable dynamic import of javascript modules

This has some risks as it can (attempt to) load arbitrary files on the
filesystem but for now it can only load local files which do go through
normal file operations. But let's enable it for now to see what we can
do with it.
This commit is contained in:
davidot 2022-01-19 10:49:51 +01:00 committed by Linus Groh
parent 986ad3ccf0
commit 2d4b345bb1

View file

@ -40,6 +40,8 @@ Workbook::Workbook(NonnullRefPtrVector<Sheet>&& sheets, GUI::Window& parent_wind
m_main_execution_context.realm = &m_interpreter->realm();
m_main_execution_context.is_strict_mode = true;
MUST(m_vm->push_execution_context(m_main_execution_context, m_interpreter->global_object()));
m_vm->enable_default_host_import_module_dynamically_hook();
}
bool Workbook::set_filename(const String& filename)