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

Separate out "public API" utils from private ones #52

Open
domenic opened this issue Aug 19, 2017 · 0 comments
Open

Separate out "public API" utils from private ones #52

domenic opened this issue Aug 19, 2017 · 0 comments

Comments

@domenic
Copy link
Member

domenic commented Aug 19, 2017

In particular, jsdom at least uses:

  • wrapperForImpl
  • implForWrapper
  • tryWrapperForImpl
  • tryImplForWrapper

But it imports these from the same generated utils.js file that also exports a bunch of other stuff, like mixin, implSymbol, iterInteralSymbol, etc.

Instead we should have something like webidl2js-utils.js (public API, those above) and webidl2js-wrapper-helpers.js (private API, the rest). Of course, webidl2js-wrapper-helpers.js can re-export the contents of webidl2js-utils.js so that the wrappers only have to import one file.

Then we can document the public ones.

domenic added a commit that referenced this issue Aug 20, 2017
Now includes the generated wrapper class file API, guidance on writing implementation class files, and documentation for the generated utils.js file.

See #52, #53, #54, #55, and #56 for oddities discovered during the course of writing this, which we hope to clean up later. (Many of them having to do with functionality that should not be considered public, and as such is not documented here, but is exposed as if it were public.)
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

No branches or pull requests

1 participant