show_password

0.0.3 • Public • Published

ShowPassword

The easiest way to show and hide the text inside a password field.

demo

Install

npm install show_password --save

Usage

Note: To use in a Node project, you'll have to use a package like jsdom to access to document object.

var ShowPassword = require('show_password')

ShowPassword.initialize()

Add a wrapper div with an id of showPassword around your password input field.

<div class="showPassword">
  <input type="password">
</div>

That's it!

Rails setup

yarn add show_password

Then, add the following to application.js:

//= require show_password/show_password

Configuration

You can use the ShowPassword.config object to configure ShowPassword.

config.color: Change the color of the visibility icons.

Author

Garrett Martin

Readme

Keywords

Package Sidebar

Install

npm i show_password

Weekly Downloads

0

Version

0.0.3

License

MIT

Unpacked Size

6.05 kB

Total Files

5

Last publish

Collaborators

  • garrettqmartin