From d4a68bbf86e30abbdf7dfa51bfd2495dcaadd285 Mon Sep 17 00:00:00 2001 From: nzbr Date: Thu, 4 Jan 2024 20:50:25 +0100 Subject: [PATCH] speechbubbles: log sticker path --- web/html-postprocessors/speechbubbles.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/web/html-postprocessors/speechbubbles.ts b/web/html-postprocessors/speechbubbles.ts index b75d6ad..965a202 100644 --- a/web/html-postprocessors/speechbubbles.ts +++ b/web/html-postprocessors/speechbubbles.ts @@ -5,12 +5,14 @@ import { toPosixPath } from '@nzbr/parcel-transformer-postprocess-html'; export const name = 'speechbubbles'; -export function fn({ $, asset, options, config }: StepInputs): void { +export function fn({ $, asset, options, config, logger }: StepInputs): void { const projectRoot = toPosixPath(options.projectRoot); const possibleCopperflameRoot = path.posix.join(projectRoot, 'node_modules', '@nzbr', 'copperflame'); const root = fs.existsSync(possibleCopperflameRoot) ? possibleCopperflameRoot : projectRoot; const stickers = config.stickerPath ?? path.posix.join(root, 'assets', 'stickers'); + logger.info({message: `Using stickers from ${stickers}`}); + asset.invalidateOnFileCreate({ glob: path.posix.join(stickers, '*'), });