Skip to content

Commit f4e7f6f

Browse files
NandkishorJadouncoderabbitai[bot]danielroeautofix-ci[bot]
authored
fix: update npm username regex to support underscores and dots (#1134)
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: Daniel Roe <daniel@roe.dev> Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
1 parent 2a7d055 commit f4e7f6f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

shared/schemas/user.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import * as v from 'valibot'
22

3-
const NPM_USERNAME_RE = /^[a-z0-9]([a-z0-9-]*[a-z0-9])?$/i
3+
const NPM_USERNAME_RE = /^[a-z0-9]([\w.-]*[a-z0-9])?$/i
44
const NPM_USERNAME_MAX_LENGTH = 50
55

66
/**

0 commit comments

Comments
 (0)