Scripts

JS functions


Ajax load page

This theme use Pjax to load page with ajax function and use css transition to adding animation on switching pages.

  <script src="../libs/pjax/pjax.js"></script>
  <script src="../assets/js/ajax.js"></script>

Find the page transtion in ../assets/js/ajax.js file and add your own page transition.

Lazy load plugins

This theme use lazy loading function to load the modules & components.

  <script src="../assets/js/lazyload.config.js"></script>
  <script src="../assets/js/lazyload.js"></script>
  <script src="../assets/js/plugin.js"></script>
How to use
  • Config the plugins in the lazyload.config.js file.
  • Add the plugin name in the page element. <div data-plugin="PluginName">