getAttachmentPlacement
Judges where an attachment sits against the attachment folder of one note.
Asks the attachment-path seam once, folder-only, for the REAL attachment, so a Custom Attachment Location folder template that reads the attachment’s own name is honoured and no name is generated.
Import:
import { getAttachmentPlacement } from '@mnaoumov/obsidian-lib/misplaced-attachment';Signature:
function getAttachmentPlacement(params: GetAttachmentPlacementParams): Promise<AttachmentPlacement>Parameters:
| Parameter | Type | Description |
|---|---|---|
params |
GetAttachmentPlacementParams | The attachment and the note. |
Returns: Promise<AttachmentPlacement> — The note’s proper folder for the attachment, and whether the attachment is in it.
Links to this page: