Code Monkey home page Code Monkey logo

vue-enter-to-tab's Introduction

vue-enter-to-tab

A mixin to use the enter key as tab key behavior. You can see a demo here.

Install

NPM:

npm i --save vue-enter-to-tab

Usage instructions

Install the mixin globally on your main file. It's required to install it as follows:

import VueEnterToTab from 'vue-enter-to-tab';

Vue.use(VueEnterToTab, initialStatus);

Where initialStatus indicates if the mixin is enabled or not initially. By default, it's true.

How to use it

After the installation, you can use the mixin on the component you need:

import {EnterToTabMixin} from 'vue-enter-to-tab';
export default {
  ...
  mixins: [EnterToTabMixin],
  ...
}

Other Utilities

Name Description Type
$isEnterToTabEnabled Data to indicate if mixin is enable Boolean
$enabledEnterToTab Method to enable the mixin Method
$disableEnterToTab Method to disable the mixin Method
$setEnterToTabStatus Method to set manually the mixin status. It receives as only paramater the status to set Method
$toggleEnterToTab Method to toggle the mixin status Method
v-prevent-enter-tab Directive to use in those inputs you want to avoid use enter as key Directive

These utilities are available globally, on all Vue instance.

Note: This directive doesn't work on textarea elements.

Any contribution is welcome. Visit my web page here.

License

MIT

vue-enter-to-tab's People

Contributors

ajomuch92 avatar l3d00m avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.