Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

188
Visualizações
(Vue js) change the vue data by click the button

I would like to click the button and change the vuejs data in formdata.eventname. But it does nothing after I click the button

Moreover, I don't know how to use vue.js in stackoverflow. If you know it, plz help me to edit the question

< script src = "https://unpkg.com/vue" >
<script >
  new Vue({
    el: "#app",
    data: {
      total: parseInt("<%= total %>"),
      events: [],
      current: 1,
      perPage: 2,
      rangeBefore: 1,
      rangeAfter: 1,
      order: "",
      size: "",
      isSimple: false,
      isRounded: false,
      prevIcon: "chevron-left",
      nextIcon: "chevron-right",
      formdata: {
        eventname: "eventname2",
        organizer: "",
        starttime: "",
        endtime: "",
        venue: "",
      },
    },
     methods: {
      submitform: async function () {
        this.formdata.eventname = "eventname1";
      },
  }); 
</script>
<button class="button is-link" @click="submitform()">Submit</button>

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

I make a stupid mistake. I didn't put the button inside the app.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda