File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
test/unit/modules/compiler Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -221,7 +221,7 @@ function processPre (el) {
221
221
function processRawAttrs ( el ) {
222
222
const l = el . attrsList . length
223
223
if ( l ) {
224
- const attrs = el . attrs = new Array ( l )
224
+ const attrs = el . staticAttrs = new Array ( l )
225
225
for ( let i = 0 ; i < l ; i ++ ) {
226
226
attrs [ i ] = {
227
227
name : el . attrsList [ i ] . name ,
Original file line number Diff line number Diff line change @@ -95,8 +95,8 @@ describe('parser', () => {
95
95
it ( 'v-pre directive' , ( ) => {
96
96
const ast = parse ( '<div v-pre id="message1"><p>{{msg}}</p></div>' , baseOptions )
97
97
expect ( ast . pre ) . toBe ( true )
98
- expect ( ast . attrs [ 0 ] . name ) . toBe ( 'id' )
99
- expect ( ast . attrs [ 0 ] . value ) . toBe ( '"message1"' )
98
+ expect ( ast . staticAttrs [ 0 ] . name ) . toBe ( 'id' )
99
+ expect ( ast . staticAttrs [ 0 ] . value ) . toBe ( '"message1"' )
100
100
expect ( ast . children [ 0 ] . children [ 0 ] . text ) . toBe ( '{{msg}}' )
101
101
} )
102
102
You can’t perform that action at this time.
0 commit comments