fix(fast rebuild): call only required emitters, don't always copy assets (#845)
* fix(fast rebuild): call only required emitters, don't always copy assets * Type function
This commit is contained in:
parent
389f2e8bee
commit
226891b9b1
2 changed files with 12 additions and 5 deletions
|
@ -203,8 +203,9 @@ async function partialRebuildFromEntrypoint(
|
|||
const emitterGraph =
|
||||
(await emitter.getDependencyGraph?.(ctx, processedFiles, staticResources)) ?? null
|
||||
|
||||
// emmiter may not define a dependency graph. nothing to update if so
|
||||
if (emitterGraph) {
|
||||
// only update the graph if the emitter plugin uses the changed file
|
||||
// eg. Assets plugin ignores md files, so we skip updating the graph
|
||||
if (emitterGraph?.hasNode(fp)) {
|
||||
// merge the new dependencies into the dep graph
|
||||
dependencies[emitter.name]?.updateIncomingEdgesForNode(emitterGraph, fp)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue