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

Access global Buffer conditionally #15

Merged
merged 2 commits into from
Jan 21, 2021
Merged

Conversation

denis-sokolov
Copy link
Contributor

@denis-sokolov denis-sokolov commented Jan 18, 2021

Enables to run the code in environments where the global Buffer is undefined, i.e. in the browsers.

Related issue: #14

Checklist

@Eomm
Copy link
Member

Eomm commented Jan 18, 2021

Would you mind to add a unit test?
I think an headless browser will be necessary to archive it, but I didn't do that before

@denis-sokolov
Copy link
Contributor Author

I could try. Could you assure me you agree with the premise to make the package run in the browsers?

I expect we’ll need additional testing tooling beyond what the project already has. Do you have preferences, are you particularly opinionated about it?

@mcollina
Copy link
Member

I have used airtap in the past and it works really well.

@denis-sokolov denis-sokolov mentioned this pull request Jan 18, 2021
4 tasks
@kibertoad kibertoad mentioned this pull request Jan 18, 2021
4 tasks
index.js Outdated Show resolved Hide resolved
@denis-sokolov denis-sokolov force-pushed the patch-1 branch 2 times, most recently from 0ae5342 to 0bb2f18 Compare January 20, 2021 10:43
Enables to run the code in environments where the global Buffer is undefined, i.e. in the browsers.
Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm

@kibertoad kibertoad merged commit f3179e6 into fastify:master Jan 21, 2021
@denis-sokolov denis-sokolov deleted the patch-1 branch January 21, 2021 14:08
@denis-sokolov
Copy link
Contributor Author

@mcollina, please release 2.3.0 at your convenience for us to enjoy the browser compatibility. Other outstanding PRs are non-functional from the user’s point of view.

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.

7 participants