Skip to content

Commit 6fe07eb

Browse files
committed
chore: merge branch '2.6' into dev
2 parents 99343f9 + edf7df0 commit 6fe07eb

File tree

109 files changed

+4100
-1841
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

109 files changed

+4100
-1841
lines changed

.circleci/config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ workflows:
9393
filters:
9494
branches:
9595
only:
96+
- "2.6"
9697
- regression-test
9798
requires:
9899
- test-cover

BACKERS.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
2121
<img width="260px" src="https://raw.githubusercontent.com/vuejs/vuejs.org/master/themes/vue/source/images/stdlib.png">
2222
</a>
2323
</p>
24-
24+
2525
<!--special end-->
2626

2727
<h2 align="center">Platinum via Patreon</h2>
@@ -320,12 +320,12 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
320320

321321
<!--50 start-->
322322
- Wasim Khamlichi
323-
- errorrik
323+
- errorrik
324324
- Alex Balashov
325325
- Konstantin Levinski
326326
- Ernest Sim
327327
- Blaise Laflamme
328-
- Dilettant
328+
- Dilettant
329329
<!--50 end-->
330330

331331
<h2 align="center">Backers via Patreon</h2>
@@ -344,10 +344,10 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
344344
- Kirk Lewis
345345
- Karol F
346346
- Miljan Aleksic
347-
- 叶解
347+
- 叶解
348348
- Jake Ingman
349349
- Barbara Liau
350-
- 4
350+
- 4
351351
- Jarek Tkaczyk
352352
- Niannian Modisette
353353
- Ivan Sieder
@@ -396,12 +396,12 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
396396
- Jere Sjöroos
397397
- Wakana Seki
398398
- David Ang
399-
- Dom
399+
- Dom
400400
- Ben Hong
401401
- David Kaplan
402402
- John Cleveland
403403
- Jaeyoung Lee
404-
- Amor
404+
- Amor
405405
- Tom Ootes
406406
- Andy Foster
407407
- Joe Cochran
@@ -428,10 +428,10 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
428428
- Yusuke Kawabata
429429
- Nick Dandakis
430430
- JI CAI
431-
- 龙腾道
431+
- 龙腾道
432432
- Milos Stojanovic
433433
- Matkovsky Peter
434-
- shimbaco
434+
- shimbaco
435435
- Princeyesuraj Edward
436436
- Kenneth Crawford
437437
<!--10 end-->

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Funds donated via Patreon go directly to support Evan You's full-time work on Vu
3131
<img width="260px" src="https://raw.githubusercontent.com/vuejs/vuejs.org/master/themes/vue/source/images/stdlib.png">
3232
</a>
3333
</p>
34-
34+
3535
<!--special end-->
3636

3737
<h3 align="center">Platinum Sponsors</h3>

benchmarks/ssr/common.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
'use strict'
22

3-
const self = (global || root)
3+
const self = (global || root) // eslint-disable-line
44

55
self.performance = {
66
now: function () {
@@ -35,11 +35,11 @@ module.exports = {
3535
}
3636
},
3737
// template: '<table><tr v-for="row in grid"><th>123</th><td v-for="item in row.items">{{ item.id }}</td></tr></table>',
38-
template: '<table width="100%" cellspacing="2"><row v-for="row in grid" :row="row"></row></table>',
38+
template: '<table width="100%" cellspacing="2"><row v-for="row in grid" :key="row.id" :row="row"></row></table>',
3939
components: {
4040
row: {
4141
props: ['row'],
42-
template: '<tr><th>{{ Math.random() }}</th><column v-for="item in row.items"></column></tr>',
42+
template: '<tr><th>{{ Math.random() }}</th><column v-for="item in row.items" :key="item.id"></column></tr>',
4343
components: {
4444
column: {
4545
template: '<td class="item">' +

dist/vue.common.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1927,7 +1927,7 @@ function withMacroTask (fn) {
19271927
try {
19281928
return fn.apply(null, arguments)
19291929
} finally {
1930-
useMacroTask = false;
1930+
useMacroTask = false;
19311931
}
19321932
})
19331933
}
@@ -11078,7 +11078,3 @@ function getOuterHTML (el) {
1107811078
return container.innerHTML
1107911079
}
1108011080
}
11081-
11082-
Vue.compile = compileToFunctions;
11083-
11084-
module.exports = Vue;

dist/vue.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/vue.runtime.common.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1918,7 +1918,7 @@ function withMacroTask (fn) {
19181918
try {
19191919
return fn.apply(null, arguments)
19201920
} finally {
1921-
useMacroTask = false;
1921+
useMacroTask = false;
19221922
}
19231923
})
19241924
}
@@ -8103,7 +8103,3 @@ if (inBrowser) {
81038103
}
81048104
}, 0);
81058105
}
8106-
8107-
/* */
8108-
8109-
module.exports = Vue;

flow/compiler.js

Lines changed: 37 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ declare type CompilerOptions = {
66
isUnaryTag?: (tag: string) => ?boolean; // check if a tag is unary for the platform
77
canBeLeftOpenTag?: (tag: string) => ?boolean; // check if a tag can be left opened
88
isReservedTag?: (tag: string) => ?boolean; // check if a tag is a native for the platform
9-
preserveWhitespace?: boolean; // preserve whitespace between elements?
9+
preserveWhitespace?: boolean; // preserve whitespace between elements? (Deprecated)
10+
whitespace?: 'preserve' | 'condense'; // whitespace handling strategy
1011
optimize?: boolean; // optimize static content?
1112

1213
// web specific
@@ -18,6 +19,7 @@ declare type CompilerOptions = {
1819
shouldDecodeTags?: boolean;
1920
shouldDecodeNewlines?: boolean;
2021
shouldDecodeNewlinesForHref?: boolean;
22+
outputSourceRange?: boolean;
2123

2224
// runtime user-configurable
2325
delimiters?: [string, string]; // template delimiters
@@ -27,13 +29,19 @@ declare type CompilerOptions = {
2729
scopeId?: string;
2830
};
2931

32+
declare type WarningMessage = {
33+
msg: string;
34+
start?: number;
35+
end?: number;
36+
};
37+
3038
declare type CompiledResult = {
3139
ast: ?ASTElement;
3240
render: string;
3341
staticRenderFns: Array<string>;
3442
stringRenderFns?: Array<string>;
35-
errors?: Array<string>;
36-
tips?: Array<string>;
43+
errors?: Array<string | WarningMessage>;
44+
tips?: Array<string | WarningMessage>;
3745
};
3846

3947
declare type ModuleOptions = {
@@ -53,11 +61,14 @@ declare type ModuleOptions = {
5361
declare type ASTModifiers = { [key: string]: boolean };
5462
declare type ASTIfCondition = { exp: ?string; block: ASTElement };
5563
declare type ASTIfConditions = Array<ASTIfCondition>;
64+
declare type ASTAttr = { name: string; value: any; start?: number; end?: number };
5665

5766
declare type ASTElementHandler = {
5867
value: string;
5968
params?: Array<any>;
6069
modifiers: ?ASTModifiers;
70+
start?: number;
71+
end?: number;
6172
};
6273

6374
declare type ASTElementHandlers = {
@@ -70,18 +81,24 @@ declare type ASTDirective = {
7081
value: string;
7182
arg: ?string;
7283
modifiers: ?ASTModifiers;
84+
start?: number;
85+
end?: number;
7386
};
7487

75-
declare type ASTNode = ASTElement | ASTText | ASTExpression;
88+
declare type ASTNode = ASTElement | ASTText | ASTExpression
7689

7790
declare type ASTElement = {
7891
type: 1;
7992
tag: string;
80-
attrsList: Array<{ name: string; value: any }>;
93+
attrsList: Array<ASTAttr>;
8194
attrsMap: { [key: string]: any };
95+
rawAttrsMap: { [key: string]: ASTAttr };
8296
parent: ASTElement | void;
8397
children: Array<ASTNode>;
8498

99+
start?: number;
100+
end?: number;
101+
85102
processed?: true;
86103

87104
static?: boolean;
@@ -91,8 +108,8 @@ declare type ASTElement = {
91108
hasBindings?: boolean;
92109

93110
text?: string;
94-
attrs?: Array<{ name: string; value: any }>;
95-
props?: Array<{ name: string; value: string }>;
111+
attrs?: Array<ASTAttr>;
112+
props?: Array<ASTAttr>;
96113
plain?: boolean;
97114
pre?: true;
98115
ns?: string;
@@ -150,6 +167,9 @@ declare type ASTElement = {
150167

151168
// weex specific
152169
appendAsTree?: boolean;
170+
171+
// 2.6 $slot check
172+
has$Slot?: boolean
153173
};
154174

155175
declare type ASTExpression = {
@@ -160,6 +180,10 @@ declare type ASTExpression = {
160180
static?: boolean;
161181
// 2.4 ssr optimization
162182
ssrOptimizability?: number;
183+
start?: number;
184+
end?: number;
185+
// 2.6 $slot check
186+
has$Slot?: boolean
163187
};
164188

165189
declare type ASTText = {
@@ -169,6 +193,10 @@ declare type ASTText = {
169193
isComment?: boolean;
170194
// 2.4 ssr optimization
171195
ssrOptimizability?: number;
196+
start?: number;
197+
end?: number;
198+
// 2.6 $slot check
199+
has$Slot?: boolean
172200
};
173201

174202
// SFC-parser related declarations
@@ -179,7 +207,8 @@ declare type SFCDescriptor = {
179207
script: ?SFCBlock;
180208
styles: Array<SFCBlock>;
181209
customBlocks: Array<SFCBlock>;
182-
};
210+
errors: Array<string | WarningMessage>;
211+
}
183212

184213
declare type SFCBlock = {
185214
type: string;

flow/global-api.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ declare interface GlobalAPI {
1616
component: (id: string, def?: Class<Component> | Object) => Class<Component>;
1717
filter: (id: string, def?: Function) => Function | void;
1818

19+
observable: <T>(value: T) => T;
20+
1921
// allow dynamic method registration
2022
[key: string]: any
2123
};

flow/options.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ declare type ComponentOptions = {
4444
beforeDestroy?: Function;
4545
destroyed?: Function;
4646
errorCaptured?: () => boolean | void;
47+
ssrPrefetch?: Function;
4748

4849
// assets
4950
directives?: { [key: string]: Object };

0 commit comments

Comments
 (0)