A static file download component can be configured by using the
!file specifier in a link.
By default, the text of the file download component is not required. Retype will automatically use the file name as the text.
The text can be explicitly set by passing as the first part of the component config. In the following sample, we explicitly set the text to
Clicking anywhere within the file download component will trigger the web browser to download the static file.
icon used for the file download component can be customized using a name/value pair syntax for the
icon attributes. This allows for setting a custom
text value at the same time.
The following sample demonstrates setting a custom
By default, the file name is used as the component text value but the text can be customized by explicityly passing a separate
[!file icon="rocket" text="To the moon"](../static/sample.txt)