Functions
Deprecated functions
The following Canvas functions are considered deprecated.
It is recommended that you use the alternative functions listed below.
Canopy elements
Alternatives: Canopy Blocks
The Canopy element functions are deprecated together with the original Canopy editor. Canopy Blocks replace them, letting content editors manage whole sections instead of individual fields. The deprecated functions are:
file
Alternatives: include
file returns the file path:
{{ file('path/to/file') }}Arguments
| Argument | Description | Type |
|---|---|---|
filepath | The path to the file | String |
import
Alternatives: include
import returns the contents of a file:
{{ import('includes/messages.html') }}The import function no longer renders HTML content within the imported file.
Arguments
| Argument | Description | Type |
|---|---|---|
filepath | The path to the file, relative to the views directory | String |
Last updated on