Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

dm-menus

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dm-menus

- [Introduction](#Introduction) - [Usage](#usage) - [Components](#components) - [Input](#input) - [Select](#select) - [Textarea](#textarea) - [Checkbox](#checkbox) - [Radio](#radio)

  • 0.1.0
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

Menu

  • Introduction
  • Usage
  • Components

Introduction

Vue Inputs is a package that bundles common form inputs using Bootstrap 4 framework. Each component acts as a wrapper, making it much easier to use form elements without the need to repeat labels, validation and other classes, help blocks.

Installation

npm install vue-inputs --save

Usage

Including this plugin in your VueJS application is very simple. This will register all available components globally, so you can use them anywhere in your application.

import FormInputs from 'vue-inputs'

Vue.use(FormInputs)

Components

All components have validator injected into them from parent component, so you don't need to worry about checking for errors. If error with same name as name property is found, validation error will be show on component.

Available props
PropTypesDefaultDescription
labelString, Boolean-Label to show on the input. If false, label is not shown.
nameString-Input's name
valueany-Automatically injected when using v-model
inlineBooleanfalseShow label and input inline
input-groupBooleanfalseShow input group addon. Makes slot input-group-append available. (form-input only)
optionsArray-Options for select (form-select only)
idStringauto generatedID (form-checkbox and form-radio only)
Input
<form-input
    label="First Name"
    name="first_name"
    v-model="user.firstName"
></form-input>
Select
<form-select
    label="Role"
    name="role_id"
    v-model="user.roleId"
    :options="roles"
></form-select>

Select component accepts array of objects as options:

roles: [
  { text: 'Select Role', value: null },
  { text: 'Administrator', value: 1 },
  { text: 'Subscriber', value: 2 }
]
Textarea
<form-textarea
    label="Content"
    name="content"
    v-model="post.content"
></form-textarea>
Checkbox
<form-checkbox
    label="I agree to terms and conditions"
    name="terms_and_conditions"
    v-model="user.terms_and_conditions"
></form-checkbox>
Radio
<form-radio
    label="Blue"
    name="color"
    value="blue"
    v-model="product.color"
></form-radio>

FAQs

Package last updated on 11 Jan 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc