chore: remove ssr
check in integrations
This commit is contained in:
parent
95e560ec41
commit
ba27eaae55
5 changed files with 0 additions and 5 deletions
|
@ -2,7 +2,6 @@ import { h, render } from 'preact';
|
||||||
import StaticHtml from './static-html.js';
|
import StaticHtml from './static-html.js';
|
||||||
|
|
||||||
export default (element) => (Component, props, children) => {
|
export default (element) => (Component, props, children) => {
|
||||||
if (!element.hasAttribute('ssr')) return;
|
|
||||||
render(
|
render(
|
||||||
h(Component, props, children != null ? h(StaticHtml, { value: children }) : children),
|
h(Component, props, children != null ? h(StaticHtml, { value: children }) : children),
|
||||||
element
|
element
|
||||||
|
|
|
@ -12,7 +12,6 @@ function isAlreadyHydrated(element) {
|
||||||
|
|
||||||
export default (element) =>
|
export default (element) =>
|
||||||
(Component, props, children, { client }) => {
|
(Component, props, children, { client }) => {
|
||||||
if (!element.hasAttribute('ssr')) return;
|
|
||||||
const componentEl = createElement(
|
const componentEl = createElement(
|
||||||
Component,
|
Component,
|
||||||
props,
|
props,
|
||||||
|
|
|
@ -6,7 +6,6 @@ export default (element) => (Component, props, childHTML, { client }) => {
|
||||||
if (!window._$HY) {
|
if (!window._$HY) {
|
||||||
window._$HY = { events: [], completed: new WeakSet(), r: {} };
|
window._$HY = { events: [], completed: new WeakSet(), r: {} };
|
||||||
}
|
}
|
||||||
if (!element.hasAttribute('ssr')) return;
|
|
||||||
|
|
||||||
const fn = client === 'only' ? render : hydrate;
|
const fn = client === 'only' ? render : hydrate;
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,6 @@ import SvelteWrapper from './Wrapper.svelte';
|
||||||
|
|
||||||
export default (target) => {
|
export default (target) => {
|
||||||
return (component, props, children, { client }) => {
|
return (component, props, children, { client }) => {
|
||||||
if (!target.hasAttribute('ssr')) return;
|
|
||||||
delete props['class'];
|
delete props['class'];
|
||||||
try {
|
try {
|
||||||
new SvelteWrapper({
|
new SvelteWrapper({
|
||||||
|
|
|
@ -3,7 +3,6 @@ import StaticHtml from './static-html.js';
|
||||||
|
|
||||||
export default (element) => (Component, props, children, { client }) => {
|
export default (element) => (Component, props, children, { client }) => {
|
||||||
delete props['class'];
|
delete props['class'];
|
||||||
if (!element.hasAttribute('ssr')) return;
|
|
||||||
|
|
||||||
// Expose name on host component for Vue devtools
|
// Expose name on host component for Vue devtools
|
||||||
const name = Component.name ? `${Component.name} Host` : undefined;
|
const name = Component.name ? `${Component.name} Host` : undefined;
|
||||||
|
|
Loading…
Reference in a new issue