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

106
Visualizações
I can't call a Highcharts Vue Reflow function

When I try to call reflow function for my graphic of highcharts when the size of vue-grid-layout change, happened this error I wanna to my graphic of same size of div, even though the size change by user

enter image description here

I don't any idea what I do

template>
    <Main>

      <grid-layout :layout.sync="layout"
                 :col-num="12"
                 :row-height="30"
                 :is-draggable="draggable"
                 :is-resizable="resizable"
                 :vertical-compact="true"
                 :use-css-transforms="true"
                 @layout-created="layoutCreatedEvent"
                 @layout-before-mount="layoutBeforeMountEvent"
                 @layout-mounted="layoutMountedEvent"
                 @layout-ready="layoutReadyEvent"
                 @layout-updated="layoutUpdatedEvent"
      >
        <grid-item v-for="item in layout"
                   :x="item.x"
                   :y="item.y"
                   :w="item.w"
                   :h="item.h"
                   :i="item.i"
                   @resize="resizeEvent"
                   @move="moveEvent"
                   @resized="resizedEvent"
                   @container-resized="containerResizedEvent"
                   @moved="movedEvent"
                   class="card"
        >
          <Charts type="chartOptions" ref="charts"></Charts>
        </grid-item>
      </grid-layout>

    </Main>
</template>
<script>
  import Main from "../Main";
  import Charts from "../../components/Charts";
  import VueGridLayout from 'vue-grid-layout';

  export default {
    name: 'home',
    components: {
      Main,
      Charts,
      GridLayout: VueGridLayout.GridLayout,
      GridItem: VueGridLayout.GridItem
    },
    methods: {
      resizeEvent: function(i, newH, newW, newHPx, newWPx){
        this.$refs.charts[i].chart.reflow();
      },
    },
    data () {
      return {
        columns: {xss: 1, xs: 1, sm: 2, md: 2, lg: 4},
        layout: [
          {"x":0,"y":0,"w":4,"h":10,"i":"0"},
          {"x":4,"y":0,"w":4,"h":10,"i":"1"}
        ]
      }
    }
  }
</script>

When I try to call reflow function for my graphic of highcharts when the size of vue-grid-layout change, happened this error I wanna to my graphic of same size of div, even though the size change by user

about 4 years ago · Juan Pablo Isaza
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