Skip to content

Commit

Permalink
jsr module path fix
Browse files Browse the repository at this point in the history
  • Loading branch information
tugrul committed May 2, 2024
1 parent fbc15bd commit 04b427e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
5 changes: 2 additions & 3 deletions jsr.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
"name": "@tugrul/async-replace",
"description": "A lightweight TypeScript module for asynchronous string replacement with concurrency limiting.",
"version": "1.0.4",
"exports": "./mod.ts"
"version": "1.0.5",
"exports": "./src/index.ts"
}
1 change: 0 additions & 1 deletion mod.ts

This file was deleted.

2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export type ReplaceCallback = (match: string, groups: string[], index: number, i
* @param limit - Optional. The maximum number of replacements to make concurrently. Default is 0 (no limit).
* @returns A Promise resolving to the modified string after replacements.
*/
export async function replace(str: string, regex: RegExp, callback: ReplaceCallback, limit: number = 0): string {
export async function replace(str: string, regex: RegExp, callback: ReplaceCallback, limit: number = 0): Promise<string> {

let last = 0;
let match = null;
Expand Down

0 comments on commit 04b427e

Please sign in to comment.