We have a very stable playwright library to handle with custom UI elements in our applications, like Date Picker, Custom File Uploader, login form etc.
Instead of putting hundred lines of code into .md file like running-code.md, it would be great to just import required function from the module and call it. Just 2 lines instead of hundred.
According to https://nodejs.org/api/vm.html#support-of-dynamic-import-in-compilation-apis
it would be enough to add importModuleDynamically - option to the \playwright\packages\playwright-core\src\tools\backend\runCode.ts