# scrollgress **Repository Path**: a1401358759/scrollgress ## Basic Information - **Project Name**: scrollgress - **Description**: A simple, lightweight jQuery plugin used to display a progress bar at the top of the page that fills up as the user scrolls. - **Primary Language**: JavaScript - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2021-05-25 - **Last Updated**: 2021-05-25 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Scrollgress Inspired by [Pitchfork](http://pitchfork.com/features/staff-lists/9466-the-top-200-tracks-of-2010-2014/), Scrollgress is a simple, lightweight jQuery plugin used to display a progress bar at the top of the page that fills up as the user scrolls. Progress can be measured as the user scrolls the page or an element that has
`overflow: scroll | auto` or `overflow-y: scroll | auto`. See a demo See a demo using an overflow element ## Instructions Include jQuery and the plugin in the head or footer of your page. ```html ``` Initialize the plugin targeting the class, ID or element that you want to display the scroll progress of. ```js $('body').scrollgress(); ``` #### Options
  1. height: "Npx"
    A string that defines the height of the progress bar in pixels (default: '5px').
  2. color: color
    A string that defines the color of the progress bar (default: '#ff0000').
  3. success: function()
    A callback function that runs after scrollgress has been initiated (default: function()).
  4. complete: function()
    A callback function that runs after you've reached the end of the page (default: function()).
##### Example: ```js $(function() { $('.post').scrollgress({ height: '10px', color: '#990000', success: function() { console.log('Scrollgress has been initiated.'); } }); }); ```