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

Add strict type checking for Uint8Array/ArrayBuffer #5849

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

robwalch
Copy link
Collaborator

@robwalch robwalch commented Sep 25, 2023

This PR will...

  • Add strict type checking for Uint8Array/ArrayBuffer and fix errors.
  • Include tsconfig in eslint settings.

Why is this Pull Request needed?

Enforce the use of ArrayBuffers vs Uint8Array so that we pass the correct type to user-agents that may be strict about the type provided.

This should also help avoid unnecessary copying of data by creating new views from typed arrays (copy = new Uint8Array(uint8Arr)).

Are there any points in the code the reviewer needs to double check?

Resolves issues:

Checklist

  • changes have been done against master branch, and PR does not conflict
  • new unit / functional tests have been added (whenever applicable)
  • API or design changes are documented in API.md

@robwalch robwalch force-pushed the task/strict-arraybuffer-uint8array-type-checking branch from b4811b4 to f8b66dc Compare October 2, 2023 19:12
@robwalch robwalch force-pushed the task/strict-arraybuffer-uint8array-type-checking branch from f8b66dc to 6bbc731 Compare October 4, 2023 18:28
@robwalch robwalch changed the title Add strict type checking for Uint8Array/ArrayBuffer and fix errors Add strict type checking for Uint8Array/ArrayBuffer Dec 2, 2023
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.

None yet

1 participant