Coder Social home page Coder Social logo

highcharts-js-rails's People

Contributors

agrobbin avatar tanelj avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

highcharts-js-rails's Issues

How do you use a theme?

How would one enable a theme for highcharts? If we include it in the asset pipeline then it gets loaded in before Highcharts.js and thus will not work.

Conflict with highcharts-rails gem

highcharts-rails gem has a Highcharts module, whereas in this gem it is a class. Is it possible to make them play nicely? Perhaps by creating a class Highcharts::Chart as I did in my library which I started, which does likewise with this one.

No option for stacking

I tried the following...

chart.plotOptions(series: {stacking: 'percent'})

which of course doesn't work, since I note that there is no built-in way to handle stacking, so I tried the following:

class Highcharts
class PlotOptions
class PlotType < Base

  def initialize(opts = {})
    @suboptions = {
      :dataLabels => 'Labels',
      :dial => 'Base',
      :events => 'PlotOptions::PlotType::Events',
      :marker => 'PlotOptions::PlotType::Marker',
      :pivot => 'Base',
      :point => 'Point',
      :states => 'PlotOptions::PlotType::States',
      :stacking => 'Base'
    }
    super
  end

end

end
end

Of course Base wants a Hash.

I also tried creating a custom class and setting the class constant string above to 'Stacking':

class Highcharts
class Stacking < Base

def initialize(opts = {})
  @default = :percent
  super
end

end
end

This sort-of works, but it renders as a 'normal' stacking and isn't settable.

If I want to do a quick hack by dropping in a new class definition or definitions, can you suggest how to go about it?

Otherwise, adding stacking to this library would be good.

Can't use latest themes

I would like to use dark-unica but it cannot find it, I assume because the included highcharts is out of date (dark unica is from 7 months ago)?

Also I would suggest somewhere in the readme specifying that you need to add
//= require highcharts in the application.js

Can't handle more than one series

Given the following, the second will overwrite the first...

chart.series(name: 'foo', ...)
chart.series(name: 'bar', ...)

Highcharts allows for the provision of multiple series, but this Ruby interface doesn't. I'm guessing you didn't need that?

While I am working on a fix which adds an array to Highcharts::Series, and requires a change to the Highcharts class to handle series differently, if you get to it first however...

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.