To disable fullpage.js scroll after the first slide in Webflow, you need to modify how fullpage.js handles auto-scrolling after the initial section.
new fullpage('#fullpage', { ... });
Within the fullpage.js config, use the afterLoad
callback to detect when the first section has been loaded:
Add this to your fullpage config:
```javascript
afterLoad: function(origin, destination, direction){
if(destination.index === 1){
fullpage_api.setAutoScrolling(false);
}
}
```
Explanation:
destination.index === 1
targets the second section (indexes are 0-based).
fullpage_api.setAutoScrolling(false)
disables auto scroll after the user reaches that section.
If you allow navigation back to the top/first section:
Add logic to re-enable auto scroll when returning to the first slide:
```javascript
if(destination.index === 0){
fullpage_api.setAutoScrolling(true);
}
```
Full example within your fullpage initialization block:
```javascript
new fullpage('#fullpage', {
autoScrolling: true,
scrollHorizontally: true,
afterLoad: function(origin, destination, direction){
if(destination.index === 1){
fullpage_api.setAutoScrolling(false);
} else if(destination.index === 0){
fullpage_api.setAutoScrolling(true);
}
}
});
```
tag.
<script>
tag.To stop fullpage.js scrolling after the first section in Webflow, use the afterLoad
callback to disable autoScrolling
when the user reaches the second section. Re-enable if navigating back to the top. This ensures a controlled scroll experience tailored to your interaction needs.