Skip to content

Commit 678b573

Browse files
seekshivazth
authored andcommitted
Update migration.toml
1 parent da1327e commit 678b573

File tree

1 file changed

+145
-0
lines changed

1 file changed

+145
-0
lines changed

migration/migration.toml

Lines changed: 145 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,34 @@ rewrite="Array.sliceToEnd(~start=:[from])"
3333
match="Js.Array2.slice(~start=:[from], ~end_=:[to])"
3434
rewrite="Array.slice(~start=:[from], ~end=:[to])"
3535

36+
[array-filteri]
37+
match="Js.Array2.filteri"
38+
rewrite="Array.filterWithIndex"
39+
40+
[array-findi]
41+
match="Js.Array2.findi"
42+
rewrite="Array.findWithIndex"
43+
44+
[array-mapi]
45+
match="Js.Array2.mapi"
46+
rewrite="Array.mapWithIndex"
47+
48+
[array-forEachi]
49+
match="Js.Array2.forEachi"
50+
rewrite="Array.forEachWithIndex"
51+
52+
[array-splice]
53+
match="Js.Array2.spliceInPlace(~pos=:[pos], ~remove=:[remove], ~add=:[add])->ignore"
54+
rewrite="Js.Array2.splice(~start=:[pos], ~remove=:[remove], ~insert=:[add])"
55+
3656
[array-z]
3757
match="Js.Array2"
3858
rewrite="Array"
3959

60+
[js-option]
61+
match="Js.Option"
62+
rewrite="Option"
63+
4064
[string-a-slice]
4165
match="Js.String2.slice(~from=:[from], ~to_=:[to])"
4266
rewrite="String.slice(~start=:[from], ~end=:[to])"
@@ -49,6 +73,18 @@ rewrite="String.sliceToEnd(~start=:[from])"
4973
match="Js.String2.replace"
5074
rewrite="String.replaceString"
5175

76+
[string-a-substring]
77+
match="Js.String2.substring(~from=:[from], ~to_=:[to])"
78+
rewrite="String.substring(~start=:[from], ~end=:[to])"
79+
80+
[string-a-substringToEnd]
81+
match="Js.String2.substringToEnd(~from=:[from])"
82+
rewrite="String.substringToEnd(~start=:[from])"
83+
84+
[string-replaceStringByRe]
85+
match="Js.String2.replaceStringByRe"
86+
rewrite="String.replaceRegExp"
87+
5288
[string-z]
5389
match="Js.String2"
5490
rewrite="String"
@@ -89,10 +125,30 @@ rewrite="Dict"
89125
match="Js.Dict.t"
90126
rewrite="Dict.t"
91127

128+
[js-null-make]
129+
match="Js.Null.return"
130+
rewrite="Null.make"
131+
132+
[js-null-z]
133+
match="Js.Null"
134+
rewrite="Null"
135+
136+
[js-nullable-make]
137+
match="Js.Nullable.return"
138+
rewrite="Nullable.make"
139+
92140
[js-nullable-z]
93141
match="Js.Nullable"
94142
rewrite="Nullable"
95143

144+
[js-null-undefined-make]
145+
match="Js.Null_undefined.return"
146+
rewrite="Nullable.make"
147+
148+
[js-null-undefined-z]
149+
match="Js.Null_undefined"
150+
rewrite="Nullable"
151+
96152
[js-log-z]
97153
match="Js.log"
98154
rewrite="Console.log"
@@ -109,6 +165,94 @@ rewrite="RegExp.test"
109165
match="Js.Json.t"
110166
rewrite="JSON.t"
111167

168+
[json-stringify]
169+
match="Js.Json.stringify"
170+
rewrite="JSON.stringify"
171+
172+
[json-enc-null]
173+
match="Js.Json.null"
174+
rewrite="JSON.Encode.null"
175+
176+
[json-enc-object]
177+
match="Js.Json.object_"
178+
rewrite="JSON.Encode.object"
179+
180+
[json-enc-string]
181+
match="Js.Json.string"
182+
rewrite="JSON.Encode.string"
183+
184+
[json-enc-bool]
185+
match="Js.Json.boolean"
186+
rewrite="JSON.Encode.bool"
187+
188+
[json-enc-int]
189+
match="Js.Json.int"
190+
rewrite="JSON.Encode.int"
191+
192+
[json-enc-float]
193+
match="Js.Json.number"
194+
rewrite="JSON.Encode.float"
195+
196+
[json-enc-array]
197+
match="Js.Json.array"
198+
rewrite="JSON.Encode.array"
199+
200+
[json-dec-bool]
201+
match="Js.Json.decodeBoolean"
202+
rewrite="JSON.Decode.bool"
203+
204+
[json-dec-null]
205+
match="Js.Json.decodeNull"
206+
rewrite="JSON.Decode.null"
207+
208+
[json-dec-string]
209+
match="Js.Json.decodeString"
210+
rewrite="JSON.Decode.string"
211+
212+
[json-dec-float]
213+
match="Js.Json.decodeNumber"
214+
rewrite="JSON.Decode.float"
215+
216+
[json-dec-obj]
217+
match="Js.Json.decodeObject"
218+
rewrite="JSON.Decode.object"
219+
220+
[json-dec-array]
221+
match="Js.Json.decodeArray"
222+
rewrite="JSON.Decode.array"
223+
224+
[json-classify]
225+
match="Js.Json.classify"
226+
rewrite="JSON.Classify.classify"
227+
228+
[json-classify-False]
229+
match="JSONFalse"
230+
rewrite="Bool(false)"
231+
232+
[json-classify-True]
233+
match="JSONTrue"
234+
rewrite="Bool(true)"
235+
236+
[json-classify-Null]
237+
match="JSONNull"
238+
rewrite="Null"
239+
240+
[json-classify-String]
241+
match="JSONString(:[string])"
242+
rewrite="String(:[string])"
243+
244+
[json-classify-Number]
245+
match="JSONNumber(:[float])"
246+
rewrite="Number(:[float])"
247+
248+
[json-classify-Object]
249+
match="JSONObject(:[dict])"
250+
rewrite="Object(:[dict])"
251+
252+
[json-classify-Array]
253+
match="JSONArray(:[array])"
254+
rewrite="Array(:[array])"
255+
112256
[json-t-rest]
113257
match="Js.Json"
114258
rewrite="JSON"
@@ -275,3 +419,4 @@ rewrite="Date"
275419
[js-global-a]
276420
match="Js.Global."
277421
rewrite=""
422+

0 commit comments

Comments
 (0)