File tree Expand file tree Collapse file tree 3 files changed +3
-35
lines changed
codemods/regexp-to-arkregex Expand file tree Collapse file tree 3 files changed +3
-35
lines changed Original file line number Diff line number Diff line change @@ -4,11 +4,7 @@ Migrate `new RegExp()` constructor calls to [arkregex](https://arktype.io/docs/r
44
55## What it does
66
7- This codemod automatically transforms your code to use arkregex, a type-safe regex library that provides:
8-
9- - Type inference for regex patterns
10- - Compile-time validation
11- - Better TypeScript integration
7+ This codemod automatically transforms your code to use arkregex, a type-safe regex library.
128
139### Transformation Example
1410
@@ -26,31 +22,3 @@ import { regex } from "arkregex";
2622const pattern = regex (" \\ d+" , " g" );
2723const emailRegex = regex (" ^[a-z]+@[a-z]+\\ .[a-z]+$" );
2824```
29-
30- ## Installation
31-
32- ``` bash
33- # Run from registry
34- codemod run @codemod/arkregex
35-
36- # Or run locally
37- codemod run -w workflow.yaml
38- ```
39-
40- ## Development
41-
42- ``` bash
43- # Test the transformation
44- npm test
45-
46- # Validate the workflow
47- codemod validate -w workflow.yaml
48-
49- # Publish to registry
50- codemod login
51- codemod publish
52- ```
53-
54- ## License
55-
56- MIT
Original file line number Diff line number Diff line change 11schema_version : " 1.0"
22
33name : " @codemod/regexp-to-arkregex"
4- version : " 0.1.0 "
4+ version : " 0.1.1 "
55description : " using arkregex instead of `new RegExp`"
66author :
" Amirabbas Ghasemi <[email protected] >" 77license : " MIT"
Original file line number Diff line number Diff line change 11{
22 "name" : " @codemod/regexp-to-arkregex" ,
3- "version" : " 0.1.0 " ,
3+ "version" : " 0.1.1` " ,
44 "description" : " using arkregex instead of `new RegExp`" ,
55 "type" : " module" ,
66 "devDependencies" : {
You can’t perform that action at this time.
0 commit comments