Commit c674a14
committed
fix: strip export keywords from browser-injected scripts
browserScript.ts reads compiled serialize.js and logUncaughtErrors.js
at runtime and injects them into the browser via page.evaluate().
With ESM output, these files have `export` keywords which are invalid
in non-module browser script context. Strip them on read.
Assisted-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent 9dd9337 commit c674a14
1 file changed
Lines changed: 9 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
5 | 6 | | |
| 7 | + | |
| 8 | + | |
6 | 9 | | |
7 | | - | |
8 | | - | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
9 | 13 | | |
10 | | - | |
11 | | - | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
12 | 17 | | |
13 | 18 | | |
14 | 19 | | |
| |||
0 commit comments