Comments (3)
Hey @mavrick,
I've took a loot at zxcvbn-async
. However I have to say I am not a fan of it.
Right now zxcvbn
is a peerDependency. So it is not included into the vue-password
package. You have to install it into your app as a dependency.
This however gives you the possibility to to chunk it if you add it to your webpack config as a vendor package.
zxcvbn-async
will load it over a CDN, which is nice but you have zero control over the versioning, which version of zxcvbn
is used and more important it is a security risk. Because you have no control over the CDN path. So in the worst case scenario an update of zxcvbn-async
could point to a malicious script which then gets injected into your site.
If you want to optimize your bundle I would suggest that you use code splitting for the password component
const Password = () => import('vue-password-strength-meter')
export default {
components: { Password }
}
So it will not end up in your main bundle.
from vue-password-strength-meter.
That's fair enough, my concern is my main app bundle excluding zxcvbn
is only 500kb gzipped.
i'm using zxcvbn
again on the backend to enforce weak password checking. i'm using nuxt so the bundle is being prefetched after page load (which isn't a huge issue) but zxcvbn
is almost the same size of my application so I'm just trying to keep it as lean as possible :)
from vue-password-strength-meter.
Maybe something like https://github.com/van-nguyen/webpack-cdn-plugin or https://github.com/mastilver/dynamic-cdn-webpack-plugin could help you.
There are some ways to use CDN sources inside webpack.
And as zxcvbn
is only a peerDependency you could possibly load it from a cdn with the right config.
from vue-password-strength-meter.
Related Issues (20)
- Pressing `enter` key on input toggles the password visibility HOT 1
- Reverse "Show" / "Hide" labels HOT 1
- Add documentation
- Add $attrs directly to input field HOT 3
- Add options for custom hide/show labels
- Blur event and input class customization HOT 1
- `vue-cli` support (feature request) HOT 6
- Responsive behaviour breaks
- NPM Package not updated HOT 3
- strength-meter-only - Empty payload on emitted event HOT 1
- What is "/Users/jjuszczak/Projekte/Privat/" HOT 7
- Support for zxcvbn user_inputs prop? HOT 4
- Make it possible to set id attribute for input element HOT 1
- [Vue warn]: Error in getter for watcher "passwordStrength": "TypeError: (0 , o.default) is not a function" HOT 4
- Feedback event should be emitted more aggressively
- When v-model is populated my a generate button it does not change the password strength
- Toggle icon blocks LastPass auto-fill icon HOT 2
- Vue3 support
- Any plans to support I18N for password hints in some way? HOT 1
- Use of the newest fork of zxcvbn
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vue-password-strength-meter.