Not show vertical line
See original GitHub issueHi,
I’m using plugin annotation in vue-chart-js, but not show.
What’s wrong?
<graph
ref="chartLiquid"
v-show="!isShowing"
v-if="oilshow == false"
:height="180"
:chart-data="liquid"
:options="chartOptions"
/>
<script>
import ChartAnnotationsPlugin from "chartjs-plugin-annotation";
Chart.plugins.register(ChartAnnotationsPlugin);
</script>
this.chartOptions = {
title: {
display: true,
text: responseData.map(item => item.name)
},
pan: {
enabled: true,
mode: "x"
},
zoom: {
enabled: true,
mode: "x",
speed: 0.5
},
annotation: {
events: ["click"],
annotations: [
{
type: "line",
mode: "vertical",
scaleID: "x-axis-0",
value: 900,
endValue: "1997-09-01",
borderColor: "red",
label: {
content: "TODAY",
enabled: true,
position: "top"
},
onWhell: function(e) {
console.log("veio ou não");
}
}
]
},
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (1 by maintainers)
Top Results From Across the Web
Vertical line does not show in geom_boxplot - Stack Overflow
In this answer: I've created a much bigger sample; I'm using yearmonth from tsibble for simplicity; I've solved the issue with the vertical...
Read more >Add Vertical Lines To Excel Charts Like A Pro! [Guide]
There are a few creative ways to add a vertical line to your chart bouncing around the internet. If you have landed on...
Read more >Solved: Vertical line not seen during mouse hover on the L...
Solved: Is it possible to add the vertical line on the Line and Clustered column chart when you hover mouse pointer over the...
Read more >How to Insert a Horizontal or Vertical Line in Microsoft Word
2. Go to the Home tab and then click the dropdown arrow for the Borders option in the Paragraph group. 3. Select Horizontal...
Read more >Missing vertical line in latex table - TeX - LaTeX Stack Exchange
I am using the below code for making a latex table. Unfortunately, when I compile the vertical line of last column is missing....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I had the same issue and using
scaleID: "x-axis-1",
rather thanscaleID: "x-axis-0",
solved my problem, FYI .I experienced the similar issue.
In my solution is that converting
this.options
to pure JavaScript objects.In my investigation, Vue returns data with [ob: Observer]. So that,
initConfig()
in chartjs-plugin-annotation did not work expectedly.initConfig in helper.js