Commit Graph

74 Commits

Author SHA1 Message Date
HcySunYang 49f4072c83
fix(compiler-ssr): keep the order of imports expression for the fallback branch of SSR (#3448)
fix #3447
2021-03-25 11:10:25 -04:00
Evan You 02cbbb718c perf: support only attaching slot scope ids when necessary
This is done by adding the `slotted: false` option to:

- compiler-dom
- compiler-ssr
- compiler-sfc (forwarded to template compiler)

At runtime, only slotted component will render slot fragments with
slot scope Ids. For SSR, only slotted component will add slot scope Ids
to rendered slot content. This should improve both runtime performance
and reduce SSR rendered markup size.

Note: requires SFC tooling (e.g. `vue-loader` and `vite`) to pass on
the `slotted` option from the SFC descriptoer to the `compileTemplate`
call.
2021-03-05 18:28:12 -05:00
Evan You aea88c3280 refactor: fix implementation of SFC :slotted id handling
fix #2892
2021-03-05 18:28:12 -05:00
lidlanca 012dc5a303
fix(compiler-ssr) ensure that ssrHelpers are unique after merge from parent context (#3269)
fix #3268
2021-02-25 18:25:39 -05:00
Evan You c69f4ea857 fix(compiler-ssr): avoid duplicated asset imports merged from component slot client branch
fix vitejs/vite#2034
2021-02-15 12:12:50 -05:00
Evan You fe5428db12 fix(compiler-ssr): handle v-model checkbox with true-value binding 2020-12-01 12:43:59 -05:00
Evan You 5b6266284d fix(compiler-ssr): should not render key/ref bindings in ssr 2020-11-27 12:37:26 -05:00
Evan You a5d6f8091e fix(compiler-ssr): generate correct children for transition-group
fix #2510
2020-11-27 12:22:14 -05:00
Evan You cdc9f336fd wip: new cssVars SSR integration + fix cssVars SSR injection for suspense 2020-11-17 18:54:47 -05:00
Mathieu TUDISCO 8539c0bf32
fix(compiler-ssr): fix SSR issue when dynamic and static class co-exist (#2354) 2020-10-13 16:25:15 -04:00
HcySunYang aa8dc9a507
fix(compiler-ssr): correct the variable name generated by the generator (#2065) 2020-09-15 10:00:14 -04:00
HcySunYang 7455dca11c
fix(compiler-ssr/teleport): correct the target prop of teleport (#2053) 2020-09-15 09:59:36 -04:00
Sohaib Alam 6136cf874e
chore: fix error message (#1602)
make the error message in `compiler-dom` and `compiler-ssr` a bit
cleaner and fix grammar
2020-07-16 13:36:16 -04:00
Evan You 576344d2c3 refactor(compiler): extract isStaticExp util 2020-07-13 16:48:24 -04:00
Evan You b9595e64cf feat: ssr support for `<style vars>` 2020-07-12 18:04:09 -04:00
Felix Rilling 829b35e426
chore: typo fixes (#1546)
* chore: fix typos in comments/JSDoc.

* chore: fix typo in internal function name.

* chore: fix typos in test comments/descriptions/variable names.
2020-07-08 12:32:42 +02:00
Evan You 41db49dfb7 fix(ssr): support dynamic components that resolve to element or vnode
fix #1508
2020-07-06 21:23:35 -04:00
Evan You d5dbd27193 fix(ssr): handle fallthrough attrs in ssr compile output 2020-06-26 16:55:37 -04:00
Evan You 6c60ce13e0 fix(compiler-ssr): handle comments codegen + refactor ssr codegen transform 2020-05-01 17:04:36 -04:00
HiiTea 22717772dd
chore: fix typos (#1090) 2020-05-01 09:42:58 -04:00
Evan You 08b4e8815d fix(compiler-ssr): avoid unnecessary withCtx import 2020-04-29 16:21:54 -04:00
Evan You eee5095692 refactor: rename `<portal>` to `<teleport>`
BREAKING CHANGE: `<portal>` has been renamed to `<teleport>`.

    `target` prop is also renmaed to `to`, so the new usage will be:

    ```html
    <Teleport to="#modal-layer" :disabled="isMobile">
      <div class="modal">
        hello
      </div>
    </Teleport>
    ```

    The primary reason for the renaming is to avoid potential naming
    conflict with [native portals](https://wicg.github.io/portals/).
2020-04-01 21:55:19 -04:00
Evan You 9ed9bf3687 feat(portal): SSR support for portal disabled prop 2020-03-30 11:24:29 -04:00
Evan You e866434f0c feat(portal): SSR support for multi portal shared target 2020-03-27 20:49:01 -04:00
Evan You a46f3b354d fix(compiler-ssr): should pass necessary tag names for dynamic v-bind 2020-03-16 18:24:26 -04:00
Evan You 3b40fc56db fix(compiler-ssr): fix input w/ v-bind="obj" codegen 2020-03-16 18:14:49 -04:00
Evan You 38f0269765 refactor: simplify suspense ssr + adjust behavior 2020-03-16 15:38:35 -04:00
Evan You a05d41c940 refactor(ssr): adjust ssr fragment anchor content 2020-03-13 13:05:05 -04:00
Evan You a3cc970030 feat(ssr/suspense): suspense hydration
In order to support hydration of async components, server-rendered
fragments must be explicitly marked with comment nodes.
2020-03-13 13:05:05 -04:00
Evan You 80c625dce3 feat(ssr): compiler-ssr support for Suspense 2020-03-10 16:52:31 -04:00
Evan You 3be3785f94 fix(ssr): fix ssr on-the-fly compilation + slot fallback branch helper injection 2020-03-06 14:52:15 -05:00
Evan You 11d2fb2594 refactor(fragments): remove visible anchors for fragments 2020-02-26 16:32:06 -05:00
Evan You d52ffaa202 refactor(compiler-ssr): extract portal processing + emit errors 2020-02-26 15:05:11 -05:00
Dmitry Sharshakov d8ed0e7fbf
feat(compiler-ssr): compile portal (#775) 2020-02-26 14:59:53 -05:00
Evan You 688ad92391 fix(ssr): fix class/style rendering + ssrRenderComponent export name 2020-02-14 20:48:06 -05:00
djy0 42db2fef9d
test(compiler-ssr): fix typo (#713) 2020-02-10 09:20:07 -05:00
Evan You 03680399f2 wip(ssr): use consistent attr key behavior in compiler 2020-02-09 15:32:33 -05:00
Evan You 51317af6e8 refactor(compiler): prefix all imported helpers to avoid scope collision 2020-02-07 18:53:39 -05:00
Evan You 9e51297702 fix(compiler-dom): fix duplicated transforms 2020-02-07 14:24:56 -05:00
Evan You a51e710396 wip(ssr): proper scope analysis for ssr vnode slot fallback 2020-02-07 13:56:18 -05:00
Evan You b7a74d0439 wip(ssr): ssr slot vnode fallback 2020-02-07 01:06:51 -05:00
Evan You 4659c366e0 wip(ssr): generate correct component code 2020-02-06 18:03:14 -05:00
Evan You 7984a135ca wip(ssr): scopeId in slots 2020-02-06 17:45:46 -05:00
Evan You 797cc18967 wip(ssr): element scopeId 2020-02-06 17:45:46 -05:00
Evan You 3c27bf6133 wip(compiler-ssr): built-in component fallthrough 2020-02-06 17:45:46 -05:00
Evan You bc8f91d181 refactor(ssr): prefix ssr helpers 2020-02-06 12:07:25 -05:00
Evan You f3e70b3733 wip(compiler-ssr): component slots 2020-02-06 12:05:53 -05:00
Evan You ee5ed73361 wip(ssr): basic components 2020-02-05 23:07:23 -05:00
Evan You 9b3b6962df wip(srr): slot outlet 2020-02-05 21:04:40 -05:00
Evan You 201f18b58b wip(ssr): v-model w/ dynamic type & props 2020-02-05 17:01:00 -05:00