almende / vis

⚠️ This project is not maintained anymore! Please go to https://github.com/visjs
7.86k stars 1.48k forks source link

Integrating Storybook for presenting the Demos #3364

Open wildeyes opened 6 years ago

wildeyes commented 6 years ago

I am first suggesting before writing any code, but I do intend on making a small pull request to show you how I imagine it.

Storybook is a library that generates a static website with components. The site is built using code that maps components to "clauses" and "sub-clauses" (in storybook terminology, stories and substories), the way I see it, stories map to components (e.g. each story is a type of vis graph), substories map to "different states of a component", if you will (e.g. each substory can act as a variation on the same graph, presenting it each time with different option).

In summary, Storybook can generate for vis.js a sort of catalogue of graphs with different options, presenting it in a nice way and getting people more easily into vis.js

Here's an example of Airbnb doing it for a date component. Now, storybook is reactjs oriented, but I believe it'll be worth the effort to make a minimal wrap just to allow storybook to load vis.js graphs.

I even imagine that the current demo page, can be loaded, fully as is, into storybook, as the main page.

If you all want to see a demo, I'll pull request something for starters. What do you think, oh mighty lords of vis.js?

wildeyes commented 6 years ago

@ludost @mojoaxel @yotamberk @Tooa @eymiha @bradh @wimrijnders

wimrijnders commented 6 years ago

In all honesty I will say that I am indifferent to this proposal. I checked out the Storybook link, and although it looks cool, I don't see how this can improve the ('my') programming experience.

But really, if you think this is worthwhile, by all means pursue it. Maybe a demo can convince me, I don't know.

What do you think, oh mighty lords of vis.js?

Err....I'm just a dude who thinks it's worthwhile to invest time in vis.js to make it better. Not much mightiness felt here, but that might be attributable to lack of coffee.

wildeyes commented 6 years ago

mmm the lords reference might be too much GoT... :)

This definitely won't improve your programming experience. I think it'll help with 2 scenarios, Make it easier to contribute examples, and make it easier for non-developers / higher-ups to browse the examples (and choose to use vis instead of X), because of the sidebar loading dynamically the examples.

It might improve your programming experience, if one incorporates automatic snapshot testing (like jest), but that's like, way further down the line.

I'll take that as a "yes, that sounds interesting, let's see a PR"

On Mon, Aug 14, 2017 at 12:22 PM, wimrijnders notifications@github.com wrote:

In all honesty I will say that I am indifferent to this proposal. I checked out the Storybook link, and although it looks cool, I don't see how this can improve the ('my') programming experience.

But really, if you think this is worthwhile, by all means pursue it. Maybe a demo can convince me, I don't know.

What do you think, oh mighty lords of vis.js?

Err....I'm just a dude who thinks it's worthwhile to invest time in vis.js to make it better. Not much mightiness felt here, but that might be attributable to lack of coffee.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/almende/vis/issues/3364#issuecomment-322140605, or mute the thread https://github.com/notifications/unsubscribe-auth/ABk1jO9c_-bT-WlQ4NCUZyR4MI7pNXcgks5sYBG3gaJpZM4O2Cnc .

wimrijnders commented 6 years ago

I'll take that as a "yes, that sounds interesting, let's see a PR"

A demo would be in order as a first step. Aside from my 'indifference', I appreciate it hugely that you are prepared to spend time to make this project better. Looking forward to be dazzled.

yotamberk commented 6 years ago

@wimrijnders , @wildeyes is a good friend of mine. We plan to have a short pair programming session to see how this storybook might help us. I hope we can make a cool demo soon