Skip to content

Commit 45b3204

Browse files
committed
Fix: rename raw → rawName
1 parent 945f453 commit 45b3204

File tree

25 files changed

+51
-51
lines changed

25 files changed

+51
-51
lines changed

src/ast/nodes.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -627,7 +627,7 @@ export interface VIdentifier extends HasLocation, HasParent {
627627
type: "VIdentifier"
628628
parent: VAttribute
629629
name: string
630-
raw: string
630+
rawName: string
631631
}
632632

633633
export interface DirectiveKeyParts {

src/html/intermediate-tokenizer.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ export class IntermediateTokenizer {
359359
loc: {start: token.loc.start, end: token.loc.end},
360360
parent: DUMMY_PARENT,
361361
name: token.value,
362-
raw: this.text.slice(token.range[0], token.range[1]),
362+
rawName: this.text.slice(token.range[0], token.range[1]),
363363
},
364364
value: null,
365365
}

src/template/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ function createDirectiveKey(node: VIdentifier): VDirectiveKey {
7878
raw,
7979
}
8080
const id = node.name
81-
const rawId = node.raw
81+
const rawId = node.rawName
8282
let i = 0
8383

8484
if (node.name.startsWith(":")) {

test/fixtures/ast/attributes/ast.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a",
149-
"raw": "a"
149+
"rawName": "a"
150150
},
151151
"value": null
152152
}
@@ -260,7 +260,7 @@
260260
}
261261
},
262262
"name": "a",
263-
"raw": "a"
263+
"rawName": "a"
264264
},
265265
"value": null
266266
}
@@ -374,7 +374,7 @@
374374
}
375375
},
376376
"name": "a",
377-
"raw": "a"
377+
"rawName": "a"
378378
},
379379
"value": {
380380
"type": "VLiteral",
@@ -505,7 +505,7 @@
505505
}
506506
},
507507
"name": "a",
508-
"raw": "a"
508+
"rawName": "a"
509509
},
510510
"value": {
511511
"type": "VLiteral",
@@ -636,7 +636,7 @@
636636
}
637637
},
638638
"name": "a",
639-
"raw": "a"
639+
"rawName": "a"
640640
},
641641
"value": {
642642
"type": "VLiteral",
@@ -767,7 +767,7 @@
767767
}
768768
},
769769
"name": "a",
770-
"raw": "a"
770+
"rawName": "a"
771771
},
772772
"value": {
773773
"type": "VLiteral",

test/fixtures/ast/cdata/ast.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "width",
149-
"raw": "Width"
149+
"rawName": "Width"
150150
},
151151
"value": {
152152
"type": "VLiteral",
@@ -201,7 +201,7 @@
201201
}
202202
},
203203
"name": "height",
204-
"raw": "heiGht"
204+
"rawName": "heiGht"
205205
},
206206
"value": {
207207
"type": "VLiteral",
@@ -256,7 +256,7 @@
256256
}
257257
},
258258
"name": "viewBox",
259-
"raw": "viewbox"
259+
"rawName": "viewbox"
260260
},
261261
"value": {
262262
"type": "VLiteral",
@@ -462,7 +462,7 @@
462462
}
463463
},
464464
"name": "d",
465-
"raw": "d"
465+
"rawName": "d"
466466
},
467467
"value": {
468468
"type": "VLiteral",

test/fixtures/ast/error-duplicate-attribute/ast.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "id",
149-
"raw": "id"
149+
"rawName": "id"
150150
},
151151
"value": {
152152
"type": "VLiteral",
@@ -201,7 +201,7 @@
201201
}
202202
},
203203
"name": "id",
204-
"raw": "id"
204+
"rawName": "id"
205205
},
206206
"value": {
207207
"type": "VLiteral",

test/fixtures/ast/error-eof-in-tag-2/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a",
149-
"raw": "a"
149+
"rawName": "a"
150150
},
151151
"value": null
152152
}

test/fixtures/ast/error-eof-in-tag-3/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a",
149-
"raw": "a"
149+
"rawName": "a"
150150
},
151151
"value": null
152152
}

test/fixtures/ast/error-eof-in-tag-4/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a",
149-
"raw": "a"
149+
"rawName": "a"
150150
},
151151
"value": {
152152
"type": "VLiteral",

test/fixtures/ast/error-eof-in-tag-5/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a",
149-
"raw": "a"
149+
"rawName": "a"
150150
},
151151
"value": {
152152
"type": "VLiteral",

test/fixtures/ast/error-eof-in-tag-6/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a",
149-
"raw": "a"
149+
"rawName": "a"
150150
},
151151
"value": {
152152
"type": "VLiteral",

test/fixtures/ast/error-eof-in-tag-7/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a",
149-
"raw": "a"
149+
"rawName": "a"
150150
},
151151
"value": {
152152
"type": "VLiteral",

test/fixtures/ast/error-missing-whitespace-between-attributes/ast.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a",
149-
"raw": "a"
149+
"rawName": "a"
150150
},
151151
"value": {
152152
"type": "VLiteral",
@@ -201,7 +201,7 @@
201201
}
202202
},
203203
"name": "c",
204-
"raw": "c"
204+
"rawName": "c"
205205
},
206206
"value": {
207207
"type": "VLiteral",

test/fixtures/ast/error-unexpected-character-in-attribute-name/ast.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a\"",
149-
"raw": "a\""
149+
"rawName": "a\""
150150
},
151151
"value": {
152152
"type": "VLiteral",
@@ -201,7 +201,7 @@
201201
}
202202
},
203203
"name": "c<d",
204-
"raw": "c<d"
204+
"rawName": "c<d"
205205
},
206206
"value": null
207207
},
@@ -239,7 +239,7 @@
239239
}
240240
},
241241
"name": "e'f",
242-
"raw": "e'f"
242+
"rawName": "e'f"
243243
},
244244
"value": {
245245
"type": "VLiteral",

test/fixtures/ast/error-unexpected-character-in-unquoted-attribute-value/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "foo",
149-
"raw": "foo"
149+
"rawName": "foo"
150150
},
151151
"value": {
152152
"type": "VLiteral",

test/fixtures/ast/error-unexpected-equals-sign-before-attribute-name/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "=abc",
149-
"raw": "=abc"
149+
"rawName": "=abc"
150150
},
151151
"value": {
152152
"type": "VLiteral",

test/fixtures/ast/error-unexpected-solidus-in-tag/ast.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "a",
149-
"raw": "a"
149+
"rawName": "a"
150150
},
151151
"value": null
152152
},
@@ -184,7 +184,7 @@
184184
}
185185
},
186186
"name": "b",
187-
"raw": "b"
187+
"rawName": "b"
188188
},
189189
"value": null
190190
}

test/fixtures/ast/error-x-invalid-namespace/ast.json

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "xmlns",
149-
"raw": "xmlns"
149+
"rawName": "xmlns"
150150
},
151151
"value": {
152152
"type": "VLiteral",
@@ -277,7 +277,7 @@
277277
}
278278
},
279279
"name": "xmlns",
280-
"raw": "xmlns"
280+
"rawName": "xmlns"
281281
},
282282
"value": {
283283
"type": "VLiteral",
@@ -408,7 +408,7 @@
408408
}
409409
},
410410
"name": "xmlns:xlink",
411-
"raw": "xmlns:xlink"
411+
"rawName": "xmlns:xlink"
412412
},
413413
"value": {
414414
"type": "VLiteral",
@@ -539,7 +539,7 @@
539539
}
540540
},
541541
"name": "xmlns:foo",
542-
"raw": "xmlns:foo"
542+
"rawName": "xmlns:foo"
543543
},
544544
"value": {
545545
"type": "VLiteral",
@@ -670,7 +670,7 @@
670670
}
671671
},
672672
"name": "xmlns",
673-
"raw": "xmlns"
673+
"rawName": "xmlns"
674674
},
675675
"value": null
676676
}
@@ -784,7 +784,7 @@
784784
}
785785
},
786786
"name": "xmlns",
787-
"raw": "xmlns"
787+
"rawName": "xmlns"
788788
},
789789
"value": {
790790
"type": "VLiteral",
@@ -915,7 +915,7 @@
915915
}
916916
},
917917
"name": "xmlns",
918-
"raw": "xmlns"
918+
"rawName": "xmlns"
919919
},
920920
"value": {
921921
"type": "VLiteral",
@@ -1046,7 +1046,7 @@
10461046
}
10471047
},
10481048
"name": "xmlns",
1049-
"raw": "xmlns"
1049+
"rawName": "xmlns"
10501050
},
10511051
"value": {
10521052
"type": "VLiteral",
@@ -1177,7 +1177,7 @@
11771177
}
11781178
},
11791179
"name": "xmlns:xlink",
1180-
"raw": "xmlns:xlink"
1180+
"rawName": "xmlns:xlink"
11811181
},
11821182
"value": {
11831183
"type": "VLiteral",

test/fixtures/ast/foreignobject/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@
202202
}
203203
},
204204
"name": "d",
205-
"raw": "d"
205+
"rawName": "d"
206206
},
207207
"value": {
208208
"type": "VLiteral",

test/fixtures/ast/html-entities-in-static-places/ast.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@
164164
}
165165
},
166166
"name": "foo",
167-
"raw": "foo"
167+
"rawName": "foo"
168168
},
169169
"value": {
170170
"type": "VLiteral",
@@ -219,7 +219,7 @@
219219
}
220220
},
221221
"name": "bar",
222-
"raw": "bar"
222+
"rawName": "bar"
223223
},
224224
"value": {
225225
"type": "VLiteral",
@@ -274,7 +274,7 @@
274274
}
275275
},
276276
"name": "baz",
277-
"raw": "baz"
277+
"rawName": "baz"
278278
},
279279
"value": {
280280
"type": "VLiteral",

test/fixtures/ast/html-entities-special-in-attributes/ast.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@
146146
}
147147
},
148148
"name": "foo",
149-
"raw": "foo"
149+
"rawName": "foo"
150150
},
151151
"value": {
152152
"type": "VLiteral",

0 commit comments

Comments
 (0)