Skip to content

Commit

Permalink
replace regex replacemend logic in iifefyFunctionFile and handle `_…
Browse files Browse the repository at this point in the history
…ENTRIES` declarations

in `iifefyFunctionFile` replace the regex replacement code that was present to prepare the
file contents to be embedded in the iife with more proper AST code modding

as part of this change make also sure that `_ENTRIES` identifiers are not modified if they
were actually declared inside the function file (as it happens in older Vercel CLI releases)
  • Loading branch information
dario-piotrowicz committed Aug 2, 2024
1 parent 2115b9e commit 273b71b
Show file tree
Hide file tree
Showing 3 changed files with 133 additions and 121 deletions.
155 changes: 49 additions & 106 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion packages/next-on-pages/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@
"miniflare": "^3.20231218.1",
"package-manager-manager": "^0.2.0",
"pcre-to-regexp": "^1.1.0",
"semver": "^7.5.2"
"semver": "^7.5.2",
"recast": "^0.23.4"
},
"devDependencies": {
"@changesets/cli": "^2.26.0",
Expand Down
Loading

0 comments on commit 273b71b

Please sign in to comment.