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

Using generator (function*) as data providers #1720

Open
arjamizo opened this issue Jun 6, 2016 · 1 comment
Open

Using generator (function*) as data providers #1720

arjamizo opened this issue Jun 6, 2016 · 1 comment
Labels
C-feature-request Category: A feature request or an enhancement

Comments

@arjamizo
Copy link

arjamizo commented Jun 6, 2016

Is this possible?

   var chart = c3.generate({
        data: {
            columns: [
                ['data2', 200, 130, 90, 240, 130, 220],
                ['data3', 300, 200, 160, 400, 250, 250],
                ['data1', 30, 20, 50, 40, 60, 50],
                (function () {var i=0; var ar = ["lab", 1,2,3]; return function*() {yield ar[i++];}})()
            ]
        }
    });

based on http://c3js.org/samples/data_columned.html

@aendra-rininsland
Copy link
Member

aendra-rininsland commented Jun 6, 2016

@arjamizo I have absolutely no idea, am thinking not, but somehow being able to use generators is an awesome idea for v1.0.

@aendra-rininsland aendra-rininsland added the C-feature-request Category: A feature request or an enhancement label Jun 6, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-feature-request Category: A feature request or an enhancement
Projects
None yet
Development

No branches or pull requests

2 participants