@lwc/ssr-compiler 8.16.2 → 8.16.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +7 -4
- package/dist/index.js +7 -4
- package/package.json +5 -5
package/dist/index.cjs.js
CHANGED
|
@@ -692,7 +692,10 @@ const bCallWiredMethod = (esTemplate `
|
|
|
692
692
|
instance.${ /*wire-decorated method*/estreeToolkit.is.identifier}(newValue)
|
|
693
693
|
`);
|
|
694
694
|
const bWireAdapterPlumbing = (esTemplate `{
|
|
695
|
-
|
|
695
|
+
// Callable adapters are expressed as a function having an 'adapter' property, which
|
|
696
|
+
// is the actual wire constructor.
|
|
697
|
+
const AdapterCtor = ${ /*wire adapter constructor*/estreeToolkit.is.expression}?.adapter ?? ${ /*wire adapter constructor*/0};
|
|
698
|
+
const wireInstance = new AdapterCtor((newValue) => {
|
|
696
699
|
${ /*update the decorated property or call the decorated method*/estreeToolkit.is.expressionStatement};
|
|
697
700
|
});
|
|
698
701
|
wireInstance.connect?.();
|
|
@@ -705,7 +708,7 @@ const bWireAdapterPlumbing = (esTemplate `{
|
|
|
705
708
|
// this preserves the behavior of the browser-side wire implementation as well as the
|
|
706
709
|
// original SSR implementation.
|
|
707
710
|
wireInstance.update(getLiveConfig(), undefined);
|
|
708
|
-
__connectContext(
|
|
711
|
+
__connectContext(AdapterCtor, instance, (newContextValue) => {
|
|
709
712
|
wireInstance.update(getLiveConfig(), newContextValue);
|
|
710
713
|
});
|
|
711
714
|
}
|
|
@@ -763,7 +766,6 @@ const bGenerateMarkup = (esTemplate `
|
|
|
763
766
|
});
|
|
764
767
|
|
|
765
768
|
__establishContextfulRelationship(contextfulParent, instance);
|
|
766
|
-
${ /*connect wire*/estreeToolkit.is.statement}
|
|
767
769
|
|
|
768
770
|
instance[__SYMBOL__SET_INTERNALS](
|
|
769
771
|
props,
|
|
@@ -776,6 +778,7 @@ const bGenerateMarkup = (esTemplate `
|
|
|
776
778
|
instance.connectedCallback();
|
|
777
779
|
__mutationTracker.disable(instance);
|
|
778
780
|
}
|
|
781
|
+
${ /*connect wire*/estreeToolkit.is.statement}
|
|
779
782
|
// If a render() function is defined on the class or any of its superclasses, then that takes priority.
|
|
780
783
|
// Next, if the class or any of its superclasses has an implicitly-associated template, then that takes
|
|
781
784
|
// second priority (e.g. a foo.html file alongside a foo.js file). Finally, there is a fallback empty template.
|
|
@@ -2567,5 +2570,5 @@ function compileTemplateForSSR(src, filename, options, mode = shared.DEFAULT_SSR
|
|
|
2567
2570
|
|
|
2568
2571
|
exports.compileComponentForSSR = compileComponentForSSR;
|
|
2569
2572
|
exports.compileTemplateForSSR = compileTemplateForSSR;
|
|
2570
|
-
/** version: 8.16.
|
|
2573
|
+
/** version: 8.16.4 */
|
|
2571
2574
|
//# sourceMappingURL=index.cjs.js.map
|
package/dist/index.js
CHANGED
|
@@ -688,7 +688,10 @@ const bCallWiredMethod = (esTemplate `
|
|
|
688
688
|
instance.${ /*wire-decorated method*/is.identifier}(newValue)
|
|
689
689
|
`);
|
|
690
690
|
const bWireAdapterPlumbing = (esTemplate `{
|
|
691
|
-
|
|
691
|
+
// Callable adapters are expressed as a function having an 'adapter' property, which
|
|
692
|
+
// is the actual wire constructor.
|
|
693
|
+
const AdapterCtor = ${ /*wire adapter constructor*/is.expression}?.adapter ?? ${ /*wire adapter constructor*/0};
|
|
694
|
+
const wireInstance = new AdapterCtor((newValue) => {
|
|
692
695
|
${ /*update the decorated property or call the decorated method*/is.expressionStatement};
|
|
693
696
|
});
|
|
694
697
|
wireInstance.connect?.();
|
|
@@ -701,7 +704,7 @@ const bWireAdapterPlumbing = (esTemplate `{
|
|
|
701
704
|
// this preserves the behavior of the browser-side wire implementation as well as the
|
|
702
705
|
// original SSR implementation.
|
|
703
706
|
wireInstance.update(getLiveConfig(), undefined);
|
|
704
|
-
__connectContext(
|
|
707
|
+
__connectContext(AdapterCtor, instance, (newContextValue) => {
|
|
705
708
|
wireInstance.update(getLiveConfig(), newContextValue);
|
|
706
709
|
});
|
|
707
710
|
}
|
|
@@ -759,7 +762,6 @@ const bGenerateMarkup = (esTemplate `
|
|
|
759
762
|
});
|
|
760
763
|
|
|
761
764
|
__establishContextfulRelationship(contextfulParent, instance);
|
|
762
|
-
${ /*connect wire*/is.statement}
|
|
763
765
|
|
|
764
766
|
instance[__SYMBOL__SET_INTERNALS](
|
|
765
767
|
props,
|
|
@@ -772,6 +774,7 @@ const bGenerateMarkup = (esTemplate `
|
|
|
772
774
|
instance.connectedCallback();
|
|
773
775
|
__mutationTracker.disable(instance);
|
|
774
776
|
}
|
|
777
|
+
${ /*connect wire*/is.statement}
|
|
775
778
|
// If a render() function is defined on the class or any of its superclasses, then that takes priority.
|
|
776
779
|
// Next, if the class or any of its superclasses has an implicitly-associated template, then that takes
|
|
777
780
|
// second priority (e.g. a foo.html file alongside a foo.js file). Finally, there is a fallback empty template.
|
|
@@ -2562,5 +2565,5 @@ function compileTemplateForSSR(src, filename, options, mode = DEFAULT_SSR_MODE)
|
|
|
2562
2565
|
}
|
|
2563
2566
|
|
|
2564
2567
|
export { compileComponentForSSR, compileTemplateForSSR };
|
|
2565
|
-
/** version: 8.16.
|
|
2568
|
+
/** version: 8.16.4 */
|
|
2566
2569
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"You can safely modify dependencies, devDependencies, keywords, etc., but other props will be overwritten."
|
|
5
5
|
],
|
|
6
6
|
"name": "@lwc/ssr-compiler",
|
|
7
|
-
"version": "8.16.
|
|
7
|
+
"version": "8.16.4",
|
|
8
8
|
"description": "Compile component for use during server-side rendering",
|
|
9
9
|
"keywords": [
|
|
10
10
|
"compiler",
|
|
@@ -49,9 +49,9 @@
|
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
51
51
|
"@babel/types": "7.26.10",
|
|
52
|
-
"@lwc/errors": "8.16.
|
|
53
|
-
"@lwc/shared": "8.16.
|
|
54
|
-
"@lwc/template-compiler": "8.16.
|
|
52
|
+
"@lwc/errors": "8.16.4",
|
|
53
|
+
"@lwc/shared": "8.16.4",
|
|
54
|
+
"@lwc/template-compiler": "8.16.4",
|
|
55
55
|
"acorn": "8.14.1",
|
|
56
56
|
"astring": "^1.9.0",
|
|
57
57
|
"estree-toolkit": "^1.7.8",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"meriyah": "^5.0.0"
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
62
|
-
"@lwc/babel-plugin-component": "8.16.
|
|
62
|
+
"@lwc/babel-plugin-component": "8.16.4",
|
|
63
63
|
"@types/estree": "^1.0.6"
|
|
64
64
|
}
|
|
65
65
|
}
|