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

Require context bounded #56

Closed
wants to merge 2 commits into from
Closed

Require context bounded #56

wants to merge 2 commits into from

Conversation

AliusDieMorietur
Copy link
Contributor

@AliusDieMorietur AliusDieMorietur commented Apr 18, 2021

Fix: #34
Now when context created require bounding to this context using closure, when require called in vm it gets value from context with Reflect if it exists.

  • tests and linter show no problems (npm t)
  • tests are added/updated for bug fixes and new features
  • code is properly formatted (npm run fmt)

Copy link
Member

@tshemsedinov tshemsedinov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need more tests for nested modules

@AliusDieMorietur
Copy link
Contributor Author

Require should have ability to work with modules in side files and replace require in there scopre and be binded to context we declared? Something like: require('../module1.js') module1.js: const fs = require('fs');

@tshemsedinov
Copy link
Member

Yes, module1 -> require(fs) and even module1 -> require(module2) -> module2 -> require(fs)

@AliusDieMorietur
Copy link
Contributor Author

Due to misclick lost conrtol on old repo, so this PR will be closed and created new #58

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.

Execute require inside MetaScript context
2 participants