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

Designating a module as library code #3640

Open
fatcerberus opened this issue Sep 5, 2017 · 6 comments
Open

Designating a module as library code #3640

fatcerberus opened this issue Sep 5, 2017 · 6 comments

Comments

@fatcerberus
Copy link
Contributor

It is possible right now to call JsParse() or JsRun() using the flag JsParseScriptAttributeLibraryCode to designate the script as library code and make it invisible to the debugger. It doesn't appear to be possible to do the same for ES modules.

Can this be done?

@akroshg
Copy link
Contributor

akroshg commented Sep 5, 2017

@fatcerberus thanks for reporting this.
@liminzhu @suwc this should be allowed, right?

@liminzhu
Copy link
Collaborator

liminzhu commented Sep 5, 2017

+@agarwal-sandeep who is familiar with the debugging APIs.

Seems reasonable that we should allow host/debugger to ignore certain modules.

@agarwal-sandeep
Copy link
Collaborator

+1 we should allow.

@fatcerberus
Copy link
Contributor Author

In my case when debugging an ES module-based codebase, the debugger's first stop tends to be one of my runtime modules, rather than the game's root module. So it'd be nice if I could step over those by default.

@dilijev
Copy link
Contributor

dilijev commented Sep 5, 2017

We have internal operations we use to do this for Intl.js library code. Maybe we can expose those as JSRT APIs?

@fatcerberus
Copy link
Contributor Author

We have internal operations we use to do this for Intl.js library code. Maybe we can expose those as JSRT APIs?

As noted above, you can already do this with normal scripts, using the parse flag JsParseScriptAttributeLibraryCode. It's just that there's no equivalent option for ES modules.

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

No branches or pull requests

5 participants