v1.3.0
a simple function to search in array, return an array of strings
Attributes
Includes Deno configuration
Repository
Current version released
9 months ago
Versions
@dallmo/array-search
overview
- a simple function to search in array, return an array of strings ;
- published on both deno land and jsr ;
usage
1. running on deno, import via deno module
nothing to add via CLI.
create a file
test-via-deno-modules.ts
import { array_search } from "https://deno.land/x/dallmo_array_search/mod.ts";
const test_array: any[] = ["aa", "abc", "a a", "b b", 123123, "123cc", "真係", "真 係 乜","唔係"];
const search_string: string = "a";
const search_result: string[] = await array_search( test_array, search_string );
console.log( search_result );
- run the test file
deno run test-via-deno-modules.ts
2. running on deno, import via jsr
usage
- in CLI, add the module with :
deno add @dallmo/array-search
- create a file
test-via-jsr.ts
import { array_search } from "@dallmo/array-search";
const test_array: any[] = ["aa", "abc", "a a", "b b", 123123, "123cc", "真係", "真 係 乜","唔係"];
const search_string: string = "a";
const search_result: string[] = await array_search( test_array, search_string );
console.log( search_result );
- run the test file
deno run test-via-jsr.ts
testing source codes
just run
deno test