Skip to main content
Module

x/aleph/std.ts>bytes.findIndex

The Full-stack Framework in Deno.
Go to Latest
function bytes.findIndex
import { bytes } from "https://deno.land/x/aleph@v0.2.27/std.ts";
const { findIndex } = bytes;

Find first index of binary pattern from a. If not found, then return -1

Parameters

source: Uint8Array

source array

pat: Uint8Array

pattern to find in source array

Returns

number