···221221222222export type QuartzEmitterPluginInstance = {
223223 name: string
224224- emit(ctx: BuildCtx, content: ProcessedContent[], resources: StaticResources): Promise<FilePath[]>
224224+ emit(
225225+ ctx: BuildCtx,
226226+ content: ProcessedContent[],
227227+ resources: StaticResources,
228228+ ): Promise<FilePath[]> | AsyncGenerator<FilePath>
229229+ partialEmit?(
230230+ ctx: BuildCtx,
231231+ content: ProcessedContent[],
232232+ resources: StaticResources,
233233+ changeEvents: ChangeEvent[],
234234+ ): Promise<FilePath[]> | AsyncGenerator<FilePath> | null
225235 getQuartzComponents(ctx: BuildCtx): QuartzComponent[]
226236}
227237```
228238229229-An emitter plugin must define a `name` field, an `emit` function, and a `getQuartzComponents` function. `emit` is responsible for looking at all the parsed and filtered content and then appropriately creating files and returning a list of paths to files the plugin created.
239239+An emitter plugin must define a `name` field, an `emit` function, and a `getQuartzComponents` function. It can optionally implement a `partialEmit` function for incremental builds.
240240+241241+- `emit` is responsible for looking at all the parsed and filtered content and then appropriately creating files and returning a list of paths to files the plugin created.
242242+- `partialEmit` is an optional function that enables incremental builds. It receives information about which files have changed (`changeEvents`) and can selectively rebuild only the necessary files. This is useful for optimizing build times in development mode. If `partialEmit` is undefined, it will default to the `emit` function.
243243+- `getQuartzComponents` declares which Quartz components the emitter uses to construct its pages.
230244231245Creating new files can be done via regular Node [fs module](https://nodejs.org/api/fs.html) (i.e. `fs.cp` or `fs.writeFile`) or via the `write` function in `quartz/plugins/emitters/helpers.ts` if you are creating files that contain text. `write` has the following signature:
232246
+1-1
docs/index.md
···3232## 🔧 Features
33333434- [[Obsidian compatibility]], [[full-text search]], [[graph view]], note transclusion, [[wikilinks]], [[backlinks]], [[features/Latex|Latex]], [[syntax highlighting]], [[popover previews]], [[Docker Support]], [[i18n|internationalization]], [[comments]] and [many more](./features/) right out of the box
3535-- Hot-reload for both configuration and content
3535+- Hot-reload on configuration edits and incremental rebuilds for content edits
3636- Simple JSX layouts and [[creating components|page components]]
3737- [[SPA Routing|Ridiculously fast page loads]] and tiny bundle sizes
3838- Fully-customizable parsing, filtering, and page generation through [[making plugins|plugins]]