Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

127
Views
ligero-gráficos - ¿Cómo configurar el color de fondo de un gráfico en negro?

Estoy usando la biblioteca javascript [lightweight-charts] para generar algunos gráficos. Para este ejemplo, estoy usando el gráfico de emulación en tiempo real .

En este ejemplo, el color de fondo es blanco. Me gustaría establecer el color de fondo en negro. Estoy siguiendo la documentación pero no puedo lograr el objetivo.

El siguiente es el código que estoy usando pero no funciona:

 var chart = LightweightCharts.createChart(document.getElementById('chart'), { width: 1200, height: 800, background: '#000000', textColor: '#ffffff' }); var candleSeries = chart.addCandlestickSeries(); var data = [...]

¿Qué me estoy perdiendo?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Deberá envolver tanto el fondo como el color del texto dentro de una propiedad de layout como

 var chart = LightweightCharts.createChart(document.getElementById('chart'), { width: 1200, height: 800, layout: { background: { color: '#000000' }, textColor: '#ffffff' } });

como se ve en este documento

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!