Search code examples
javascriptvue.jshighchartsbar-chartcube.js

How to set vertical bar chart in Hightcharts | I passed as component. How to send as props


I imported Bar-chart from High charts. Its shown as horizontal bar. I need to show as Vertical Chart. Please help me to show as vertical chart. Need to pass as props

<template v-slot="{ measures, resultSet, loading}">
   <bar-chart type:"vertical" :data="transformData(resultSet)"></bar-chart>
</template>

Hope you understand my problem. Bar chart is shown as Horizontal. Need to show as Vertical bar chart.


Solution

  • Most probably you can show bar chart as horizontal only. If you want show your bar chart as vertical. Better you can go with column chart. column chart will helps you shown as vertical bar chart. Please try this code

    <template v-slot="{ measures, resultSet, loading}">
       <column-chart :data="transformData(resultSet)"></column-chart>
    </template>
    

    I hope you will get answer for this.