From 0527006a5494133f09e7aebd00d2bc7555df1372 Mon Sep 17 00:00:00 2001 From: Max Schmitt Date: Wed, 6 Sep 2023 22:57:12 +0200 Subject: [PATCH] docs(test-typescript): rename transpilation issues doc (#26893) --- docs/src/test-typescript-js.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/test-typescript-js.md b/docs/src/test-typescript-js.md index 0cb5cc8b63..6062954a43 100644 --- a/docs/src/test-typescript-js.md +++ b/docs/src/test-typescript-js.md @@ -88,7 +88,7 @@ The `pretest` script runs typescript on the tests. `test` will run the tests tha Then `npm run test` will build the tests and run them. -## Transpilation issues +## Using `import` inside `evaluate()` Using dynamic imports inside a function passed to various `evaluate()` methods is not supported. This is because Playwright uses `Function.prototype.toString()` to serialize functions, and transpiler will sometimes replace dynamic imports with `require()` calls, which are not valid inside the web page.