Skip to content

pascalvgemert/vue-instant-page

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

vue-instant-page

Make your site’s pages instant with this Vue Plugin and improve your conversion rate.

This is the VueJS Plugin equivalent of the https://instant.page/ script.

Installation

Install through npm

npm install vue-instant-page --save

Add the plugin to Vue in main.js/app.js:

// Require dependencies
var Vue = require('vue');
var VueInstantPage = require('vue-instant-page');

// Tell Vue to use the plugin
Vue.use(VueInstantPage);

Options

Vue.use(VueInstantPage, {
    /** Delay of mouse hover in milliseconds after when the prefetching can begin */
    delayOnHover: 65,

    /** Use mousedown as a prefetch trigger */
    useMousedown: false,

    /** Only use mousedown as a prefetch trigger, and disabled mouse hover */
    useMousedownOnly: false,

    /** All pages with a query string be preloaded when set to true */
    allowQueryString: false,

    /** External links aren’t preloaded by default, to allow them all set this variable to true */
    allowExternalLinks: false,

    /** Only preload specific links when use whitelist is set to true */
    useWhitelist: false,
});

Big thanks to instant.page and Alexandre Dieulot

I converted the instant.page script into a VueJS Plugin.

To view the original JS source: https://github.com/instantpage/instant.page To get more info about the code: https://instant.page/

About

Make your site’s pages instant with this Vue Plugin and improve your conversion rate.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published