Commit Graph

1733 Commits

Author SHA1 Message Date
Evan You
dbf627f136 wip(runtime): support multi-element static vnode in renderer 2020-05-15 15:12:26 -04:00
Evan You
cb9444807e wip(compiler): improve node stringification to support adjacent nodes 2020-05-15 12:58:44 -04:00
Evan You
c2f3ee4dc0 chore: use jsdoc comments in ast 2020-05-15 11:00:07 -04:00
Evan You
3c88299f6a release: v3.0.0-beta.12 2020-05-11 15:52:37 -04:00
Evan You
2bc6a8c1cf fix(hmr): static child traversal should only affect elements 2020-05-11 15:46:30 -04:00
Evan You
aa1672a8bd test: fix hmr test id 2020-05-11 15:44:13 -04:00
Evan You
7887c54dfe release: v3.0.0-beta.11 2020-05-11 14:25:36 -04:00
Evan You
1b946c85df fix(hmr): always force full child component props update in HMR mode 2020-05-11 14:17:35 -04:00
Evan You
5b8883a846 fix(runtime-core): should not take unmount children fast path for v-for fragments
fix #1153
2020-05-11 13:53:28 -04:00
underfin
697de07e63
fix(transition): should reset enter class after appear (#1152) 2020-05-11 12:30:10 -04:00
Evan You
9d111f534a test(transition): refactor DOM transition test 2020-05-11 11:52:08 -04:00
Evan You
66c5a556dc fix(hmr): ensure static nodes inherit DOM element in hmr mode
fix #1156
2020-05-11 11:34:42 -04:00
Evan You
a165d8293d feat(runtime-core): expose isVNode 2020-05-11 11:09:36 -04:00
Evan You
13acb9134e release: v3.0.0-beta.10 2020-05-07 11:21:18 -04:00
underfin
66dd1aaecd
test(Transition): test transition (#1140) 2020-05-07 11:10:28 -04:00
Evan You
d10835aee7 fix(compiler-sfc): template with alt lang should be parsed as raw text
fix #1120
2020-05-07 11:08:17 -04:00
Evan You
e58beecc97 refactor(compiler/types): convert compiler options documentation to jsdoc
BREAKING CHANGE: `getTextMode` compiler option signature has changed from

  ```ts
  (tag: string, ns: string, parent: ElementNode | undefined) => TextModes
  ```

  to

  ```ts
  (node: ElementNode, parent: ElementNode | undefined) => TextModes
  ```
2020-05-07 11:01:36 -04:00
Evan You
304ab8c99b fix(compiler-dom): bail static stringfication on non-attr bindings
fix #1128
2020-05-07 10:32:54 -04:00
Evan You
2f69167e88 perf(compiler-sfc): only add character mapping if not whitespace 2020-05-07 10:32:54 -04:00
Evan You
675330ba54 fix(compiler): warn against v-bind with empty attribute value
ref: https://github.com/vuejs/vue-next/issues/1128#issuecomment-624647434
2020-05-07 10:32:54 -04:00
Evan You
698c8d35d5 feat(compiler-sfc): improve sfc source map generation 2020-05-07 01:37:34 -04:00
龙腾道
e08f6f0ede
fix(reactivity): use correct thisArg for collection method callbacks (#1132) 2020-05-06 13:41:34 -04:00
Evan You
8df6bc0132 refactor: reuse parseStringStyle across compiler and runtime 2020-05-06 11:22:49 -04:00
t-zzzzzzzzz
2d9f136077
fix(runtime-dom/style): normalize string when merging styles (#1127) 2020-05-06 11:14:07 -04:00
susiwen8
df4150dc4c
chore: LegacyOptions doesn't need to be exported (#1134) 2020-05-06 11:07:11 -04:00
Evan You
d66211849c fix(compiler-sfc): should not transform external asset url with
includeAbsolute: true
2020-05-06 09:41:31 -04:00
龙腾道
037fa07113
fix(reactivity): fix __proto__ access on proxy objects (#1133) 2020-05-06 09:08:44 -04:00
Evan You
c5dcfe16f6 perf(compiler-sfc): improve asset url trasnform efficiency 2020-05-05 16:07:15 -04:00
Evan You
40166a8637 feat(types): re-expose trasnformVNodeArgs 2020-05-05 10:45:33 -04:00
Evan You
c32ed52b97 release: v3.0.0-beta.9 2020-05-04 17:14:42 -04:00
Evan You
f05aeea7ae fix(transitionGroup): fix transition children resolving condition 2020-05-04 17:09:19 -04:00
Evan You
6a0be882d4 feat(compiler-sfc): support transforming absolute asset urls
BREAKING CHANGE: `@vue/compiler-sfc`'s `transformAssetUrlsBase` option
has been removed. It is merged into `trasnformAssetUrls` which now also
accepts the format of

  ```ts
  {
    base?: string
    includeAbsolute?: string
    tags?: { [name: string]: string[] }
  }
  ```
2020-05-04 16:45:19 -04:00
Evan You
f9a3766fd6 fix(compiler): bail strigification on runtime constant expressions 2020-05-04 15:15:26 -04:00
Evan You
3c3fe88c64 release: v3.0.0-beta.8 2020-05-04 10:49:23 -04:00
underfin
26a50ce67f
fix(transitionGroup): inner children should skip comment node (#1105) 2020-05-04 10:41:48 -04:00
Evan You
3c60d40827 feat(shared): support Map and Set in toDisplayString
close #1067, close #1100
2020-05-04 10:38:03 -04:00
Evan You
ff97be15c3 chore: ensure warn is dev only 2020-05-04 10:17:40 -04:00
Evan You
c6217b4d46 refactor(types): use pure type symbol 2020-05-04 09:38:32 -04:00
Evan You
6b33cc4229 feat(watch): support directly watching reactive object with deep default
Also warn invalid watch sources

close #1110
2020-05-04 09:27:28 -04:00
Evan You
64ef7c76bf feat(types): re-expose resolve asset utitlies and registerRuntimeCompiler in type definitions
close #1109
2020-05-04 08:52:59 -04:00
Evan You
bc1f097e29 fix(types/reactivity): fix ref type inference on nested reactive properties with .value
fix #1111
2020-05-04 08:51:17 -04:00
Evan You
f40f3a0e95 fix(reactivity): avoid polluting Object prototype 2020-05-04 08:51:17 -04:00
Jackliu
42a99d28ae
chore: typo (#1113) 2020-05-04 10:30:24 +02:00
Evan You
6be2b73f8a fix(reactivity): check own property for existing proxy of target
fix #1107
2020-05-03 15:36:19 -04:00
XinPing Wang
8bab78b648 test: reactive proto 2020-05-03 15:36:19 -04:00
Evan You
01b7e90eac fix(hmr): handle cases where instances with same id having different definitions 2020-05-03 13:52:09 -04:00
Evan You
0c48558f4c chore: remove commented stale code [ci skip] 2020-05-02 17:08:54 -04:00
Evan You
0dc44a6a86 release: v3.0.0-beta.7 2020-05-02 17:06:16 -04:00
Evan You
d901b6bea8 refactor(reactivity): use more efficient reactive checks
WeakSets and WeakMaps shows degrading performance as the amount of
observed objects increases. Using hidden keys result in better
performance especially when repeatedly creating large amounts of
reactive proxies.

This also makes it possible to more efficiently declare non-reactive
objects in userland.
2020-05-02 16:58:17 -04:00
Evan You
36972c20b5 feat(compiler-sfc): add transformAssetUrlsBase option 2020-05-02 16:58:17 -04:00
Eduardo San Martin Morote
71a942b25a
fix(warn): cast symbols to strings (#1103) 2020-05-02 10:26:32 -04:00
Evan You
583ba0c172 feat(types): re-expose withDirectives as public type 2020-05-02 10:19:40 -04:00
Evan You
b570287dfe release: v3.0.0-beta.6 2020-05-01 18:56:53 -04:00
HiiTea
f0d52d5428
chore: code comment formatting (#1089) [ci skip] 2020-05-01 18:48:44 -04:00
Evan You
98bee596bd fix(runtime-core): should catch dom prop set TypeErrors
based on #1051
2020-05-01 18:47:27 -04:00
Evan You
c5e7d8b532 fix(compiler-core): hoist pure annotations should apply to all nested calls 2020-05-01 18:36:34 -04:00
Evan You
cad25d95a3 fix(compiler-core): hoisted vnode calls and scoped id calls should be marked pure
Otherwise they cannot be tree-shaken
2020-05-01 17:34:11 -04:00
Evan You
6c60ce13e0 fix(compiler-ssr): handle comments codegen + refactor ssr codegen transform 2020-05-01 17:04:36 -04:00
underfin
8b85aaeea9
fix(runtime-core): should call Suspense fallback unmount hook (#1061)
fix #1059
2020-05-01 16:20:16 -04:00
Evan You
b40fcbc4c6 fix(types): augment ref unwrap bail types in appropriate packages
Packages can now augment the ref unwrap bail types in their own `d.ts`.
Also updated the build script to auto concat any files in a package's
`types` directory to the final generated `d.ts`.

- `@vue/reactivity` should no longer require `libs: ["DOM"]` in tsconfig
- Properly bail on `VNode` and `ComponentPublicInstance` in runtime-core
2020-05-01 16:14:30 -04:00
Evan You
7f23555356 fix(teleport): teleport should always be tracked as dynamic child for unmount
fix #1088
2020-05-01 15:12:07 -04:00
Evan You
08bf7e3607 fix(runtime-core): cloned vnodes with extra props should de-opt 2020-05-01 14:55:27 -04:00
Evan You
ac6a6f11ac fix(runtime-core): fix slot fragment bail check 2020-05-01 14:16:55 -04:00
Evan You
11f38d8a85 perf: instance public proxy should never be observed 2020-05-01 13:24:38 -04:00
Evan You
62336085f4 fix(runtime-core): avoid infinite warning loop for isRef check on component public proxy
fix #1091
2020-05-01 13:23:59 -04:00
Evan You
5b09e743a0 fix(ssr): fix escape and handling for raw Text, Comment and Static vnodes 2020-05-01 11:52:40 -04:00
Evan You
1bddeea247 feat(runtime-core): warn against user properties with reserved prefixes 2020-05-01 11:23:22 -04:00
Evan You
20bc7ba1c5 fix(runtime-dom): should not coerce nullish values to empty strings for non-string dom props
fix #1049
close #1092, close #1093, close #1094
2020-05-01 11:06:24 -04:00
Evan You
68e1ce8b66 refactor(types): mark more internal APIs 2020-05-01 10:37:40 -04:00
HiiTea
22717772dd
chore: fix typos (#1090) 2020-05-01 09:42:58 -04:00
Evan You
127e96a993 types: fix internal exports from @vue/shared 2020-05-01 09:19:30 -04:00
Evan You
c9bf7ded2e refactor(types): mark internal API exports and exclude from d.ts
BREAKING CHANGE: Internal APIs are now excluded from type decalrations.
2020-04-30 17:04:35 -04:00
Evan You
a5bb1d02b7 release: v3.0.0-beta.5 2020-04-30 16:20:25 -04:00
underfin
8ed3455251
fix(transition-group): should collect raw children with Fragment (#1046)
fix #1045
2020-04-30 15:06:50 -04:00
Bas van Meurs
ba240eb497
feat(runtime-core): export queuePostFlushCb (#1078) 2020-04-30 14:58:50 -04:00
Carlos Rodrigues
239270c38a
fix(keep-alive): do not invoke onVnodeBeforeUnmount if is KeepAlive component (#1079) 2020-04-30 14:52:03 -04:00
Evan You
352c369704 chore: remove stale _isVue checks 2020-04-30 14:45:25 -04:00
Evan You
386b093554 fix(hmr): support hmr for static nodes 2020-04-30 14:45:25 -04:00
Evan You
e087b4e024 fix(hydration): fix text mismatch warning 2020-04-29 17:07:41 -04:00
Evan You
08b4e8815d fix(compiler-ssr): avoid unnecessary withCtx import 2020-04-29 16:21:54 -04:00
Evan You
a0e2c12874 fix(warning): always check for component instance presence when formatting traces 2020-04-29 14:41:22 -04:00
Evan You
892fb6d229 types: use more consistent naming for apiWatch type exports
BREAKING CHANGE: Some watch API types are renamed.

    - `BaseWatchOptions` -> `WatchOptionsBase`
    - `StopHandle` -> `WatchStopHandle`
2020-04-27 13:33:57 -04:00
Evan You
8ab44e1f80 types: expose ComponentOptionsBase 2020-04-27 13:31:40 -04:00
Evan You
bd0f7da2c6 build: add browser builds for @vue/compiler-sfc 2020-04-26 01:24:25 -04:00
Evan You
0bb1f67d12 types(compiler-sfc): expose SFCAsyncStyleCompileOptions 2020-04-24 17:11:41 -04:00
Evan You
d29aefcf99 release: v3.0.0-beta.4 2020-04-24 16:20:20 -04:00
Evan You
ca84f46cd0 chore: add tip about Suspense being experimental 2020-04-24 16:13:44 -04:00
Evan You
ded92f93b4 fix(runtime-core): dynamic component should support falsy values without warning 2020-04-24 15:32:47 -04:00
Carlos Rodrigues
f3a9b516bd
fix(types): make return type of defineComponent assignable to Component type (#1032)
fix #993
2020-04-24 13:22:58 -04:00
Carlos Rodrigues
28b4c317b4
feat(types): expose ToRefs type (#1037) 2020-04-24 13:10:16 -04:00
Evan You
c9f10be9de refactor(runtime-core): extract key/ref normalization logic 2020-04-24 13:06:56 -04:00
susiwen8
ad2b940c17
chore: remove unnecessary export (#1044) [ci skip] 2020-04-24 13:02:44 -04:00
Evan You
d7379c7647 fix(runtime-core): fix key/ref resolution for cloneVNode
fix #1041
2020-04-24 12:42:46 -04:00
Evan You
dcf2458fa8 fix(runtime-core): fix dynamic node tracking in dynamic component that resolves to plain elements
fix #1039
2020-04-24 12:18:51 -04:00
Evan You
fa216a0c3a feat(compiler-sfc): built-in support for css modules 2020-04-24 09:59:52 -04:00
Evan You
20d425fb19 feat(compiler-sfc): add preprocessCustomRequire option 2020-04-24 09:28:03 -04:00
underfin
63c8444d4a
Update packages/runtime-core/src/components/BaseTransition.ts
Co-Authored-By: Carlos Rodrigues <david-181@hotmail.com>
2020-04-23 06:53:46 +08:00
Evan You
2acf3e84b9 feat(reactivity): add triggerRef API
Also make shallowRef assignment behavior consistent with normal ref
2020-04-22 18:00:10 -04:00
underfin
2b19965bcf
fix(slots): compiled slot fallback should be functions (#1030)
This avoids it being collected as dynamic children when it's not used.

fix #1021
2020-04-22 16:52:41 -04:00
Evan You
ff4d1fcd81 fix(runtime-core): mixin options that rely on this context should be deferred
Also ensure consistent option apply order with Vue 2, close #1016, close #1029
2020-04-22 16:36:18 -04:00