From 6966b94f213fc04a4d144d6ab5dca34e18c9354b Mon Sep 17 00:00:00 2001 From: cha0s Date: Sun, 13 Mar 2022 13:58:41 -0500 Subject: [PATCH] refactor(HTTP): don't build with fleck by default --- packages/http/src/server/index.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/packages/http/src/server/index.js b/packages/http/src/server/index.js index 30e471a..77dd8d8 100644 --- a/packages/http/src/server/index.js +++ b/packages/http/src/server/index.js @@ -49,6 +49,12 @@ export default { config.use.push(imageLoader()); }, '@flecks/core.build.alter': (neutrinoConfigs, flecks) => { + // Don't build if there's a fleck target. + if (neutrinoConfigs.fleck && !flecks.get('@flecks/http/server.forceBuildWithFleck')) { + // eslint-disable-next-line no-param-reassign + delete neutrinoConfigs.http; + return; + } // Bail if there's no http build. if (!neutrinoConfigs.http) { return; @@ -111,6 +117,10 @@ export default { colors: true, modules: false, }, + /** + * Force building http target even if there's a fleck target. + */ + forceBuildWithFleck: false, /** * Host to bind. */