Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report

available-typed-arrays 1.0.6

Returns an array of Typed Array names that are available in the current environment
Package summary
Share
0
issues
0
licenses
Package created
24 Jan 2020
Version published
1 Feb 2024
Maintainers
1
Total deps
0
Direct deps
0
License
MIT
Generating a report...
Hold on while we generate a fresh audit report for this package.

Frequently Asked Questions

What does available-typed-arrays do?

The "available-typed-arrays" is a handy npm package in JavaScript used to return an array of Names of Typed Arrays that are accessible in the current runtime environment. This feature can be useful when you want to perform dynamic computations and decisions based on the Typed Arrays available in your environment.

How do you use available-typed-arrays?

Using "available-typed-arrays" in your JavaScript project is straightforward. First, you need to install the package using npm with the following command npm install available-typed-arrays.

Once installed, you can then require it in your JavaScript file like this: var availableTypedArrays = require('available-typed-arrays');.

Here's an example of how to use it in your code:

var availableTypedArrays = require('available-typed-arrays');
var assert = require('assert');

assert.deepStrictEqual(availableTypedArrays(), [
	'Int8Array',
	'Uint8Array',
	'Uint8ClampedArray',
	'Int16Array',
	'Uint16Array',
	'Int32Array',
	'Uint32Array',
	'Float32Array',
	'Float64Array',
	'BigInt64Array',
	'BigUint64Array'
].sort());

In this code, we are asserting that the available Typed Arrays in our environment match the ones listed in the array.

Where are the available-typed-arrays docs?

As for the documentation for the "available-typed-arrays", it is presented directly in the project's README on its GitHub page, which can be accessed here. This documentation provides an overview of what the package does, how to install it, as well as an example of how to use it in your JavaScript project.