Coder Social home page Coder Social logo

vue-formular's People

Contributors

fuelingtheweb avatar karaoak avatar matfish2 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

vue-formular's Issues

Adding errors when using "client" mode

I can't find a possibility to inject errors into the form when using client. Is there some possibility to call sth like form.setErrors([{name: 'foo', message: 'bar'}]) or add an errors prop to vf-form/vf-field?

If not is it possible to add this functionality?

about V-select

Now I want to use a V-select without a placeholder . And I found that it will add a selectoption as default , but it will give the user update a empty value . How can I forbidden this default option ?

How to reset form errors

Hi I wish to know, how can I reset one form. For example, I have a modal form. When I close the form modal it's supposed to reset all fields. But when I reset the fields values, the errors (required) keep showing on. By the way I really loved your component, it's really clean when compared to the other I was using (vue-validator)

Bind to hasError property of the form

Great plugin, I use it with pleasure :)
Can you help me with one problem?
Is there a event which fires, when form hasErrors property is changed? I want to bind reactively to this property, so I can change accordingly one property of the parent element.

I have this structure:

<parent>
    <child>
    <vue-formular>

To achieve this I tried to create computed property in parent element

computed: {
    isValid: !this.$refs.form.hasErrors
}

but recieve this error :

Cannot read property '$refs' of undefined

When I do this with getter funtion it seems to work, until I try to bind this property to other child element

<child :valid="isValid">

and then this error is coming:

[Vue warn]: Error when evaluating expression "function get() {
    return this.$refs.form.hasErrors;
} Cannot read property 'hasErrors' of undefined

I tried to use watcher insteed, but with same errors.

Is it posible to bind to hasError property?

v-date can not disabled?

when I want to add the attribute disabled to a v-date , it can still be a white blank . No matter I set it by html or js ,it might give the user a wrong info . Is there a way to change the css ?

Unable to run with webpack/ES6/babel/?

when I try to use vue-formular with webpack I get warnings in the npm run console and the browser (chrome) also just displays a white page and an error in the console

npm run dev

WARNING in ./~/vue-formular/lib/helpers/render-template.js
Critical dependencies:
2:0-7 require function is used in a way in which dependencies cannot be statically extracted
 @ ./~/vue-formular/lib/helpers/render-template.js 2:0-7

WARNING in ./~/vue-formular/lib/helpers/render-template.js
Critical dependencies:
8:16-28 the request of a dependency is an expression
 @ ./~/vue-formular/lib/helpers/render-template.js 8:16-28

WARNING in ./~/vue-formular/lib/components/methods/validate.js
Critical dependencies:
1:16-23 require function is used in a way in which dependencies cannot be statically extracted
 @ ./~/vue-formular/lib/components/methods/validate.js 1:16-23

Chrome

render-template.js?7dd7:2          Uncaught SyntaxError: Unexpected token !

Steps to reproduce

# use default webpack template by vue-cli
vue init webpack testformular

# install stuff
cd testformular
npm install

# install vue-formular
npm i -D vue-formular

# edit src/main.js to enable vue-formular (see below)

# run dev server
npm run dev

Edit src/main.js and add this:

import VueFormular from 'vue-formular'

Vue.use(VueFormular)

Can you give me a hint how to fix this?

Issue in V-Select

Hi,
I am not sure if this is something I am doing wrong but the value returned by the v-select with the version of formular i am running returns the value of the "text" of the option instead of the id

when I copied some of my code into the demo fiddle, it returns the id correctly when i log the changed event.

what is the version of vue and vue-formular on the fiddle ?

How to add a listener by event?

I want to add a check to make sure user will save before exit.
And I found that there is a vue-formular.change event might be useful , but i can't use it as a common VUE
event .Is there any samples to use a event ?

additionalPayload doesn't respect change

I didn't find how to add type="hidden" fields so i used additionalPayload but it seems it doesn't respect the change. Submits the initial value options: {additionalPayload: {additional: 'initial value' }}

If i change it in a method this.options.additionalPayload.additional = 'asdsasds' it submits 'inital value'
Also tried with this.$set('options.additionalPayload', {additional: 'asdasdasd'}

Integration with v-model

Hi
Thanks for this component. Love the ease of use.
But how do you integrate it with v-model ?

Cheers, rk

After submit redirect via vue-router

When in /items/new after submit i want to redirect to /items/:id so i used 'vue-formular.sent' event but after dispatching it tries to set some properties (vm.status = 'success'; ...etc) on the now not existing instance which leads to error. Any suggestions?

Add autofocus / focus event

It would be nice to have a possibility to trigger focus() on a field after instantiating/showing it.

For example:
Either through a autofocus property that triggers this.field.focus() on ready
or
somehow expose the field or the focus function so I can trigger the focus() event from the component in which I'm using the vf-field.

how to get programmatically if form has validation errors

Hi
I have a question. I would like to disable the submit button on a form if the form has errors. But i would like to do it based on a computed field which looks at the field and also a values of a few other fields and then indicates whether the submit button should be enabled


computed: {
    canSubmit: function() {
        // how do i check here whether form has validation errors based on rules defined for fields ?
    }

}

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.