Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wrap/replace eval calls with function constructor calls to make the sloppy file strict-mode compliant #180

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Haringat
Copy link

Any problem in computer science can be solved by adding another layer of indirection.

This fixes all issues related with sloppy.js not being strict-mode compliant like #170 and #153
Aside from that it also provides a better separation between the evaluated code and domino as the evaluated code can no longer accidentally fall through to variables like file, require or __dirname because the function constructor code is always evaluated at top-level (where these do not exist)

@totize
Copy link

totize commented May 26, 2022

Thanks so much Haringat!
This fixed my Angular (13) SSR setup.

@KonradNowacki
Copy link

Doesnt seem to work with ng14

@Haringat
Copy link
Author

Haringat commented Aug 1, 2022

@KonradNowacki would you mind posting a stack trace please?
Also please bear in mind that this has not been merged yet so the latest package does not include the changes.

@its-dibo
Copy link

its-dibo commented Sep 5, 2022

very nice, hope to be merged very soon to fix angular/angular#45062

@magyargergo
Copy link

Hey @cscott @fgnass,

Could you please give more visibility to this PR? It would be nice to merge it/resolve it eventually.

Thanks!

@hiepxanh
Copy link

@fgnass @cscott hello, can you take a look?

@Haringat
Copy link
Author

Happy Anniversary🎂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants