一、概念与使用
1.什么是Fullpage?
Fullpage.js 是一个基于jQuery的插件,他能够很方便、很轻松的制作出全屏滚动网站。
2.什么是jQuery ?
用JS封装的一个框架、
3.为什么要学习插件或者框架?
在企业开发中因为开发时间、企业成本等因素;所以并不是所有的功能都需要我们自己实现;大部分情况下一些常用的功能都有现成的插件或者框架;我们只需要找到合适的插件或者框架,快速学习套用即可。
4.插件或者框架的来源?
个人或团队自行封装;百度、谷歌、GitHub;行业交流、技术峰会。
5.如何学习使用框架?
下载框架;查看框架实列程序;阅读框架文档;编写Demo
用法: https://github.com/alvarotrigo/fullPage.js/tree/master/lang/chinese#fullpagejs
6. 先添加 .JS 文件:
具体包括fullpage.css , jquery-3.1.1.js ,easings.js , scrolloverflow.js , fullpage.js
7. 要求HTML结构:
<div id="fullpage">
<div class="section">Some section</div>
<div class="section">Some section</div>
<div class="section">Some section</div>
<div class="section">Some section</div>
</div>
8.初始化相关:
<Script>
new fullpage('#fullpage', {
//options here
autoScrolling:true,
scrollHorizontally: true
//其他相关属性可在网页 https://github.com/alvarotrigo/fullPage.js/tree/master/lang/chinese#fullpagejs 中查看
});
</script>
-End