Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposal: pass more arguments in event handlers #132

Open
siloam opened this issue Apr 26, 2022 · 3 comments
Open

Proposal: pass more arguments in event handlers #132

siloam opened this issue Apr 26, 2022 · 3 comments

Comments

@siloam
Copy link

siloam commented Apr 26, 2022

Development Relevant Information:

  • BalmUI version: 10.4.0 | 10.5.0
  • Browser: Chrome
  • Operating System: Windows 10

Description:

v-model is working fine but I got undefined while typing at @change and @update:modelValue events

Steps To Reproduce:

Try it yourself

@elf-mouse
Copy link
Member

Sorry @siloam , I did not reproduce the problem

<ui-textfield
  :model-value="value"
  @update:model-value="onInput"
  @change="onChange"
></ui-textfield>
export default {
  data() {
    return {
      value: ''
    };
  },
  methods: {
    onInput(value) {
      console.log('onInput', value);
    },
    onChange(event) {
      console.log('onChange', event);
    }
  }
};

@siloam
Copy link
Author

siloam commented Apr 26, 2022

I've inspected it futher. Event handler can pass only one value. Is this possible to modify this mechanism to pass more values in the handler? Something like onHandle(event/value, ...args) to pass more arguments?

@siloam siloam changed the title ui-textfield events are not working properly Proposal: pass more arguments in event handlers Apr 26, 2022
@elf-mouse
Copy link
Member

See the default event handler definition.
Can you provide actual usage scenarios?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants