Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix writing strings to the writable stream writer (#32637)
Only chunks are allowed to write to writable. This fixes the following error in the web runtime: ``` Uncaught (in promise) TypeError: This TransformStream is being used as a byte stream, but received a string on its writable side. If you wish to write a string, you'll probably want to explicitly UTF-8-encode it with TextEncoder. ``` It doesn't fail in the Node.js sandbox since we polyfilled this case (which should be reverted back later). ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
- Loading branch information