Position
You are reading an outdated document
Get the latest developer guides on Fynd Partners Help
Intro
Positions are slots (gaps) exposed by theme where extension elements can be injected. Positions are created using action component fdk-extension where templates array is taken by user through settings by input type Types of Input
Example
<template>
<div class="section-extension-root">
<!-- Extension Position -->
<fdk-extension :templates="templates" />
</div>
</template>
<!-- #region -->
<settings>
{
"name": "section_extension",
"label": "Extensions",
"props": [
{
"type": "extension",
"id": "extension",
"label": "Extension Positions",
"info": "Handle extension in these positions",
"positions": [
{
"value": "section_extension",
"text": ""
}
],
"default": {}
}
]
}
</settings>
<!-- #endregion -->
<script>
export default {
props: ["settings"],
computed: {
templates() {
return this.settings.props?.extension?.value?.["section_extension"] || []
}
}
};
</script>