mirror of
https://github.com/nuxt/nuxt.git
synced 2025-01-30 23:32:38 +00:00
commit
8cf56284ac
@ -17,11 +17,12 @@ export default {
|
||||
if (this.canRender) {
|
||||
if (
|
||||
process.env.NODE_ENV === 'development' &&
|
||||
this.$slots.default &&
|
||||
this.$slots.default.length > 1
|
||||
) {
|
||||
throw new Error('<no-ssr> You cannot use multiple child components')
|
||||
}
|
||||
return this.$slots.default[0]
|
||||
return this.$slots.default && this.$slots.default[0]
|
||||
}
|
||||
return h('div', { class: { 'no-ssr-placeholder': true } }, this.placeholder)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user