简体   繁体   English

如何在没有jQuery的情况下使用纯JavaScript制作像fullpage.js这样的快照滚动效果

[英]How to make snap scroll effect like fullpage.js with pure javascript without jQuery

looking for solution how to make this snap scrol http://alvarotrigo.com/fullPage/#firstPage but without huge script. 寻找解决方案如何制作此快照脚本http://alvarotrigo.com/fullPage/#firstPage但没有庞大的脚本。 how to make it more simple. 如何使其更简单。 will be really happy to hear your experience. 很高兴听到您的经历。

What about trying the pure Javascript fullPage.js version ? 尝试使用纯Javascript fullPage.js版本呢? :) 17Kb, although it provides less features. :) 17Kb,尽管它提供的功能较少。

By the way, fullpage.js is not a "huge script" as you said. 顺便说一句,fullpage.js并不是您所说的“巨大脚本”。 It is only 30Kb and 7Kb gzipped. 压缩后只有30Kb和7Kb。 I would say it is quite a light script in size for all the features it provides. 我要说的是,它提供的所有功能在大小上都是很简单的脚本。

You can argue you don't want to import the 80Kb of jQuery + 30 of fullpage.js, fair enough, but I wouldn't call fullPage.js a "huge script" :) 您可以说您不想导入jQuery的80Kb + fullpage.js的30Kb,这很公平,但是我不会将fullPage.js称为“巨大的脚本” :)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM