Time for action – compiling JavaScript and styling the website with media queries
Perform the following steps to compile the JavaScript files and optimize the website for a small viewport size:
Create a new JavaScript file in the
assets/js
directory namedfoundation.js
.In
foundation.js
, import the following JavaScript files:// @koala-prepend "../../components/foundation/js/vendor/jquery.js" // @koala-prepend "../../components/foundation/js/foundation/foundation.js" // @koala-prepend "../../components/foundation/js/foundation/foundation.topbar.js" // @koala-prepend "../../components/foundation/js/foundation/foundation.orbit.js"
Via Koala, compile
foundation.js
.Then, open
index.html
and add the following lines right before</body>
to enable the Orbit Slider functionalities:<script src="assets/js/foundation.min.js"></script> <script> $(document).foundation({ orbit: { timer_speed: 3000, pause_on_hover: true, resume_on_mouseout: true, slide_number...