Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: bump to Vue 3.0.0-beta.15 #141

Merged
merged 2 commits into from
Jun 25, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"ts-jest": "^25.0.0",
"tsd": "0.11.0",
"typescript": "^3.7.5",
"vue": "^3.0.0-beta.12",
"vue": "^3.0.0-beta.15",
"vue-jest": "vuejs/vue-jest#next",
"vuex": "^4.0.0-beta.1"
},
Expand Down
32 changes: 29 additions & 3 deletions src/mount.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@ import {
ExtractPropTypes,
Component,
WritableComputedOptions,
SetupContext,
RenderFunction,
ComponentOptionsBase,
ComponentPropsOptions,
AppConfig,
VNodeProps
Expand All @@ -35,14 +34,29 @@ import {
} from './constants'
import { stubComponents } from './stubs'

// TODO remove when https://github.com/vuejs/vue-next/pull/1361 is merged
type ComponentOptionsMixin = ComponentOptionsBase<
any,
any,
any,
any,
any,
any,
any,
any
>
type Slot = VNode | string | { render: Function } | Function

type SlotDictionary = {
[key: string]: Slot
}

interface MountingOptions<Props, Data = {}> {
data?: () => Data extends object ? Partial<Data> : never
data?: () => {} extends Data
? never
: Data extends object
? Partial<Data>
: never
props?: Props
attrs?: Record<string, unknown>
slots?: SlotDictionary & {
Expand Down Expand Up @@ -86,6 +100,8 @@ export function mount<
C extends ComputedOptions = {},
M extends Record<string, Function> = {},
E extends EmitsOptions = Record<string, any>,
Mixin extends ComponentOptionsMixin = ComponentOptionsMixin,
Extends extends ComponentOptionsMixin = ComponentOptionsMixin,
EE extends string = string
>(
componentOptions: ComponentOptionsWithoutProps<
Expand All @@ -95,6 +111,8 @@ export function mount<
C,
M,
E,
Mixin,
Extends,
EE
>,
options?: MountingOptions<never, D>
Expand All @@ -110,6 +128,8 @@ export function mount<
C extends ComputedOptions = {},
M extends Record<string, Function> = {},
E extends EmitsOptions = Record<string, any>,
Mixin extends ComponentOptionsMixin = ComponentOptionsMixin,
Extends extends ComponentOptionsMixin = ComponentOptionsMixin,
EE extends string = string,
Props extends Readonly<{ [key in PropNames]?: any }> = Readonly<
{ [key in PropNames]?: any }
Expand All @@ -122,6 +142,8 @@ export function mount<
C,
M,
E,
Mixin,
Extends,
EE,
Props
>,
Expand All @@ -138,6 +160,8 @@ export function mount<
C extends ComputedOptions = {},
M extends Record<string, Function> = {},
E extends EmitsOptions = Record<string, any>,
Mixin extends ComponentOptionsMixin = ComponentOptionsMixin,
Extends extends ComponentOptionsMixin = ComponentOptionsMixin,
EE extends string = string
>(
componentOptions: ComponentOptionsWithObjectProps<
Expand All @@ -147,6 +171,8 @@ export function mount<
C,
M,
E,
Mixin,
Extends,
EE
>,
options?: MountingOptions<ExtractPropTypes<PropsOptions>, D>
Expand Down
3 changes: 1 addition & 2 deletions src/stubs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@ const createStub = ({ name, props }: StubOptions): ComponentOptions => {
const tag = name ? `${hyphenate(name)}-stub` : anonName

const render = (ctx: ComponentPublicInstance) => {
// TS is not happy with this signature, so we cast the Slots as any
return h(tag, {}, getSlots(ctx) as any)
return h(tag, {}, getSlots(ctx))
}

return defineComponent({ name: name || anonName, render, props })
Expand Down
72 changes: 48 additions & 24 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1199,6 +1199,17 @@
estree-walker "^0.8.1"
source-map "^0.6.1"

"@vue/[email protected]":
version "3.0.0-beta.15"
resolved "https://registry.yarnpkg.com/@vue/compiler-core/-/compiler-core-3.0.0-beta.15.tgz#8710a8e3ba15ba1a8b62bd17609d26bd27fdcc45"
integrity sha512-NLNW7tAMHl8ybRgTPTIWLsi8aXHbFngY2x95eEHAdxhNasTY5NsgmQBBH9TBAUQEn6Wo8ybmuvQoNzgcw979Zg==
dependencies:
"@babel/parser" "^7.8.6"
"@babel/types" "^7.8.6"
"@vue/shared" "3.0.0-beta.15"
estree-walker "^0.8.1"
source-map "^0.6.1"

"@vue/[email protected]", "@vue/compiler-dom@^3.0.0-beta.12":
version "3.0.0-beta.12"
resolved "https://registry.yarnpkg.com/@vue/compiler-dom/-/compiler-dom-3.0.0-beta.12.tgz#f455898b96d421d71c808ca35b8349504a2f7ffd"
Expand All @@ -1207,6 +1218,14 @@
"@vue/compiler-core" "3.0.0-beta.12"
"@vue/shared" "3.0.0-beta.12"

"@vue/[email protected]":
version "3.0.0-beta.15"
resolved "https://registry.yarnpkg.com/@vue/compiler-dom/-/compiler-dom-3.0.0-beta.15.tgz#ee6dc9ae1dabb5c5c257d7cc20c5f3e95d5e5f4f"
integrity sha512-0qVaCosZ6XrkmlSOndGlNh33JQ2oao82uWxC/qw4QWBGm6a1DcKkZFIZFYLQWg5ZIcSrEQrR1VzUidBaZw9AIg==
dependencies:
"@vue/compiler-core" "3.0.0-beta.15"
"@vue/shared" "3.0.0-beta.15"

"@vue/compiler-sfc@^3.0.0-beta.12":
version "3.0.0-beta.12"
resolved "https://registry.yarnpkg.com/@vue/compiler-sfc/-/compiler-sfc-3.0.0-beta.12.tgz#ed93aa0f07d5d099cea7582118e05fbb7c77b1c6"
Expand All @@ -1233,35 +1252,40 @@
"@vue/compiler-dom" "3.0.0-beta.12"
"@vue/shared" "3.0.0-beta.12"

"@vue/[email protected].12":
version "3.0.0-beta.12"
resolved "https://registry.yarnpkg.com/@vue/reactivity/-/reactivity-3.0.0-beta.12.tgz#33e8c3845dc663967c85217316f831a0153c40dc"
integrity sha512-ZgqLVADzwgFvm+Jf12bfzesvV3wcZXfM6JmryZ2BrWvkGS+Xo0A4oOcnsB4Tmqw5lemdYYkoleup02ChzvRlMg==
"@vue/[email protected].15":
version "3.0.0-beta.15"
resolved "https://registry.yarnpkg.com/@vue/reactivity/-/reactivity-3.0.0-beta.15.tgz#4ee0942783d7ff09acab5b8755706597ba6234f6"
integrity sha512-Xa0LG8RTNlPYsuqOBhhV03xKhMmuSU0vtKXoIi1yxp9gGU7ga/TMmnhELb66AiupiXdLJwRcdv00KhPF/2y0dA==
dependencies:
"@vue/shared" "3.0.0-beta.12"
"@vue/shared" "3.0.0-beta.15"

"@vue/[email protected].12":
version "3.0.0-beta.12"
resolved "https://registry.yarnpkg.com/@vue/runtime-core/-/runtime-core-3.0.0-beta.12.tgz#f35fa386c319e13da682e58f171e25c2376ec865"
integrity sha512-qcgfp5VJCuObGIYPoust7l3hZONHfgJfVeVYPjaKi+asjlYwdmjTRExUahhjuHvkLdSGRY+qckS3Adga7kyMjg==
"@vue/[email protected].15":
version "3.0.0-beta.15"
resolved "https://registry.yarnpkg.com/@vue/runtime-core/-/runtime-core-3.0.0-beta.15.tgz#35c2ef61dadf07dfe9129dbea6fb8c1b88cc5bd6"
integrity sha512-jDkqSs1hsS9fRCgzah7VINafxWj7bYoDyweVuBqm6KPcHRfGkRZZxl2NltbbVaLH76Qvm4PPSnqGgEx7QtFSgg==
dependencies:
"@vue/reactivity" "3.0.0-beta.12"
"@vue/shared" "3.0.0-beta.12"
"@vue/reactivity" "3.0.0-beta.15"
"@vue/shared" "3.0.0-beta.15"

"@vue/[email protected].12":
version "3.0.0-beta.12"
resolved "https://registry.yarnpkg.com/@vue/runtime-dom/-/runtime-dom-3.0.0-beta.12.tgz#f9c0f02fb2152727ec0746517ae5ab08513d00e8"
integrity sha512-1fyDeKKX2KMZbMmxn9a/QzwYSlbzZlGz3Iy9iss/WbFFK9hNtAEWY6x4iwtw7/vJ00EE8OOMgHX3ki9fNNqSqw==
"@vue/[email protected].15":
version "3.0.0-beta.15"
resolved "https://registry.yarnpkg.com/@vue/runtime-dom/-/runtime-dom-3.0.0-beta.15.tgz#e3ce740c5e3766020719b174686bd65c75975c7e"
integrity sha512-161rUw1sWfbv51Ua8gKXaPc+seRJQcV+MLokTJtqYtNCajya0Mx6vdXJajBWqjDT8/Udx0sb7Wm/K/0DfGBUTw==
dependencies:
"@vue/runtime-core" "3.0.0-beta.12"
"@vue/shared" "3.0.0-beta.12"
"@vue/runtime-core" "3.0.0-beta.15"
"@vue/shared" "3.0.0-beta.15"
csstype "^2.6.8"

"@vue/[email protected]":
version "3.0.0-beta.12"
resolved "https://registry.yarnpkg.com/@vue/shared/-/shared-3.0.0-beta.12.tgz#cb7a2bb047919d2c944bf822032b0a8aa869ba1d"
integrity sha512-cA0DD3VFGYI76lbM90fAYXNJ9EmDNsm1tthO4FIY18DwziZKJWCfQBhEfHQd2skHcTE4OqH5eBxgsKEdn/LuGQ==

"@vue/[email protected]":
version "3.0.0-beta.15"
resolved "https://registry.yarnpkg.com/@vue/shared/-/shared-3.0.0-beta.15.tgz#77444ab234e229c3fdcc9f394678e167a55757af"
integrity sha512-wViILT5GgxMtnXVQ1xupj43wvnZ41g3NLWaBObs7l+eTxz5vq5yx72qH6HRpsfhR2Mg39jE0cfNLFEpC4lJIUQ==

abab@^2.0.0, abab@^2.0.3:
version "2.0.3"
resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.3.tgz#623e2075e02eb2d3f2475e49f99c91846467907a"
Expand Down Expand Up @@ -5983,14 +6007,14 @@ vue-jest@vuejs/vue-jest#next:
extract-from-css "^0.4.4"
ts-jest "^24.0.0"

vue@^3.0.0-beta.12:
version "3.0.0-beta.12"
resolved "https://registry.yarnpkg.com/vue/-/vue-3.0.0-beta.12.tgz#e72d1baeede285768d2df0f2b52dc79427f49419"
integrity sha512-4Y8LPplndYp48q1P8CSbG3Et/bPcMQB11edusA6SuIGmgrLdS4Ntdwpjtc9kglYHaY9/E/VTVjl4jAGqpAFR1w==
vue@^3.0.0-beta.15:
version "3.0.0-beta.15"
resolved "https://registry.yarnpkg.com/vue/-/vue-3.0.0-beta.15.tgz#99f107534755d3a237b51fc1279c43af2fefde6e"
integrity sha512-KTmvfNpkvD6mao8vloqjUMjrHEivS1HZvHmYeHPRHqU2HRvNcrZuwXYvETt3dGOTu0Oj7zAWQXP+uZ34CW75sw==
dependencies:
"@vue/compiler-dom" "3.0.0-beta.12"
"@vue/runtime-dom" "3.0.0-beta.12"
"@vue/shared" "3.0.0-beta.12"
"@vue/compiler-dom" "3.0.0-beta.15"
"@vue/runtime-dom" "3.0.0-beta.15"
"@vue/shared" "3.0.0-beta.15"

vuex@^4.0.0-beta.1:
version "4.0.0-beta.1"
Expand Down