Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

VuetifyJS Conditionally Disabling Components

BrownZeus
 Share

Hey all!

 

I'm building a webapp with VueJS, implementing Vuetify to take care of the material design stuff for me.

I was curious to know if anyone could help me figure out how to make a component disabled conditionally.

All the Vuetify components appear to support a "disabled" properties, at least the input fields, selectors and buttons do.

This property obviously doesn't allow the interaction with such disabled components. It has a default value of false, making the component its a part of, disabled (duh)

Logically, setting disabled to true should leave it enable right? Well, i tried doing that several different ways. like

 

disabled="true"

disabled:"true"

 

^I tried both of those things without the quotes as well, as well as with single quotes as well. No luck, the component stays disabled either way, using boolean values or not.

Obviously I'm doing something wrong here, I just can't pinpoint what. I couldn't find anything useful in the documentation or in the GitHub forums for it. Anyone have any ideas?

Link to comment
Share on other sites

Link to post
Share on other sites

<component :disabled="true"></component>

 

Business Management Student @ University St. Gallen (Switzerland)

HomeServer: i7 4930k - GTX 1070ti - ASUS Rampage IV Gene - 32Gb Ram

Laptop: MacBook Pro Retina 15" 2018

Operating Systems (Virtualised using VMware): Windows Pro 10, Cent OS 7

Occupation: Software Engineer

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share


×