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

Implement jsg::JsValue and related types #1014

Merged
merged 5 commits into from
Aug 21, 2023
Merged

Implement jsg::JsValue and related types #1014

merged 5 commits into from
Aug 21, 2023

Conversation

jasnell
Copy link
Member

@jasnell jasnell commented Aug 14, 2023

These are a new abstraction meant to discourage use of v8::Local directly in most cases.

See the included test for examples of use.

PR includes changes to AbortSignal/AbortController to illustrate how it is used and to verify it works.

Still todo:

  • Update the RTTI handling to ensure typescript type generation for the Js* types works as expected
  • More documentation

@jasnell jasnell force-pushed the jsnell/jsvalue branch 4 times, most recently from cea56f0 to b33f45d Compare August 16, 2023 19:07
@jasnell
Copy link
Member Author

jasnell commented Aug 16, 2023

@mrbbot ... just a heads up on this. we'll need to make sure the type mappings are generated correctly

src/workerd/jsg/jsvalue.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsvalue.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsvalue.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsvalue.h Show resolved Hide resolved
src/workerd/jsg/jsvalue.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsvalue.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsvalue.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsvalue.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsg.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsg.h Outdated Show resolved Hide resolved
@jasnell jasnell force-pushed the jsnell/jsvalue branch 5 times, most recently from 570d259 to a848863 Compare August 18, 2023 15:50
@jasnell jasnell requested a review from kentonv August 18, 2023 17:56
src/workerd/jsg/jsg.h Outdated Show resolved Hide resolved
@jasnell jasnell force-pushed the jsnell/jsvalue branch 2 times, most recently from e01f9e2 to 0480b48 Compare August 18, 2023 20:35
@jasnell jasnell requested a review from kentonv August 18, 2023 21:11
src/workerd/jsg/jsg.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsg.h Show resolved Hide resolved
src/workerd/jsg/jsvalue.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsg.h Outdated Show resolved Hide resolved
src/workerd/jsg/jsvalue.h Show resolved Hide resolved
@jasnell jasnell merged commit f9ce5c5 into main Aug 21, 2023
7 checks passed
@fhanau fhanau deleted the jsnell/jsvalue branch December 4, 2023 22:33
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.

3 participants