🔔 Alert..!! Get 2 Month Free Cloud Hosting With $200 Bonus From Digital Ocean ACTIVATE DEAL

A Vue 2+ component that conditionally prevents page leave/reload in web app.

Other

Documentation

🚪 Vue prevent unload

npm Github file size npm GitHub license Vue2

Vue component that conditionaly prevents page leave/reload

🎨 Playground on the Web

💿 Installation

This version requires Vue 2.X.

npm install vue-prevent-unload

🚀 Usage

<template>   <PreventUnload :when="hasChanges"/> </template> <script>   import PreventUnload from 'vue-prevent-unload';   export default {     data() {       return {         hasChanges: true,       }     },     components: {       PreventUnload,     }   } </script>

💉 Tests

In TODO

⚓️ Semantic Versioning Policy

This plugin follows semantic versioning.

📰 Changelog

We're using GitHub Releases.

🍻 Contributing

We're more than happy to see potential contributions, so don't hesitate. If you have any suggestions, ideas or problems feel free to add new issue, but first please make sure your question does not repeat previous ones.

Notice: Don't try to edit files from dist as it compiled from src by babel and shouldn't be changed manually.

🔒 License

See the LICENSE file for license rights and limitations (MIT).


You May Also Like