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

Usage as CDN #800

Closed
YorozuyaDev opened this issue Sep 9, 2022 · 2 comments
Closed

Usage as CDN #800

YorozuyaDev opened this issue Sep 9, 2022 · 2 comments

Comments

@YorozuyaDev
Copy link

We are trying to use this plugin and ChartJS from a CDN, but we are not able to draw the box, and no errors are reported. My code looks correct, since it works on the demo enviroment, but I paste anyway. Thanks in advance

HTML Code:

<html>
  <body>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/3.9.1/chart.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/chartjs-plugin-annotation/2.0.1/chartjs-plugin-annotation.min.js">
    </script>
    <script src="app.js"></script>
 </body>
</html>

Config

plugins: {
        autocolors: false,
        annotation: {
          annotations: {
            box1: {
              type: 'box',
              xMin: 1,
              xMax: 9,
              yMin: 1,
              yMax: 4,
              backgroundColor: 'transparent'
            },
            label1: {
              type: 'label',
              xValue: 2,
              yValue: 4.5,
              backgroundColor: 'transparent',
              content: ['Fase latente'],
              font: {
                size: 18
              }
            }
          }
        }
      },
@stockiNail
Copy link
Collaborator

@YorozuyaDev can you provide a sample (or whole chart configuration and data) to reproduce the issue, maybe using the data of environment where it doesn't work?

@stockiNail
Copy link
Collaborator

Closing as outdated, feel free to re-open with the requested additional info.

@stockiNail stockiNail closed this as not planned Won't fix, can't repro, duplicate, stale May 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants