Hi,
CMS Load provides a way to keep Webflow interactions working after loading new items. But how about keeping interactions that have been set with pure JS?
Here’s my demo: Projets
When knew items are charged below the list, the hover effects won’t work on them.
Read-only: Webflow - Studio Format
Thanks!
hey @pablo.faust! You can use the CMS Load API like this to animate newly rendered items on your list
<script>
window.fsAttributes = window.fsAttributes || [];
window.fsAttributes.push([
'cmsload',
(listInstances) => {
console.log('cmsload Successfully loaded!');
const [listInstance] = listInstances;
function itemAnimation(params) {
// code to animate CMS items with JS
}
itemAnimation();
listInstance.on('renderitems', (renderedItems) => {
itemAnimation();
});
},
]);
</script>