@@ -44,6 +44,15 @@ function buildEngineTargets(targets) {
44
44
return targets . map ( ( bundleConfig ) => buildBundleConfig ( engineConfig , bundleConfig ) ) ;
45
45
}
46
46
47
+ function buildEngineServerTargets ( targets ) {
48
+ const targetName = 'engine-server' ;
49
+ const input = getEs6ModuleEntry ( '@lwc/engine-server' ) ;
50
+ const dir = path . join ( distDirectory , 'engine-server' ) ;
51
+ const engineConfig = { input, targetName, dir } ;
52
+
53
+ return targets . map ( ( bundleConfig ) => buildBundleConfig ( engineConfig , bundleConfig ) ) ;
54
+ }
55
+
47
56
function buildSyntheticShadow ( targets ) {
48
57
const name = 'SyntheticShadow' ;
49
58
const targetName = 'synthetic-shadow' ;
@@ -72,6 +81,10 @@ function buildWireService(targets) {
72
81
...buildEngineTargets ( COMMON_TARGETS ) ,
73
82
...buildSyntheticShadow ( COMMON_TARGETS ) ,
74
83
...buildWireService ( COMMON_TARGETS ) ,
84
+ ...buildEngineServerTargets ( [
85
+ { target : 'es2017' , format : 'commonjs' , prod : false } ,
86
+ { target : 'es2017' , format : 'commonjs' , prod : true } ,
87
+ ] ) ,
75
88
] ;
76
89
process . stdout . write ( '\n# Generating LWC artifacts...\n' ) ;
77
90
await generateTargets ( allTargets ) ;
0 commit comments