FileComponent
classe · Source
Constructor
new FileComponent(data?: FileComponent | APIFileComponent)
Parameters
| Name | Type | Description |
|---|---|---|
data? | FileComponent | APIFileComponent | The data Default: {}. |
Properties
file
file: UnfurledMediaItem
This unfurled media item is unique in that it only supports attachment references using the attachment://<filename> syntax Source
spoiler
spoiler: Boolean
Whether the container should be a spoiler (or blurred out). Defaults to false. Source
Methods
toJSON
toJSON(): APIFileComponent
**Returns:** `APIFileComponent` [Source](https://github.com/AltKit/discord/blob/selfbotjs/src/structures/FileComponent.js#L40)