operational-ui icon indicating copy to clipboard operation
operational-ui copied to clipboard

Fix code examples

Open TejasQ opened this issue 6 years ago • 10 comments

So now that we moved to the Monaco Editor (#1036), some examples are invalid. You can see this by navigating through the components and clicking View Code here: https://operational-ui.netlify.com/#/Hooks/useInterval and on other components.

image

When you click View Code, you might see some errors:

image

Let's fix all these errors by editing the README.md files of each component that has them.

TejasQ avatar Jun 23 '19 15:06 TejasQ

Hey @TejasQ interested in this issue! However is their a simple way to exhaustively find these issues?

ddc22 avatar Jun 23 '19 16:06 ddc22

You could create a checker 😛

My original plan was to go through each page.

One idea is the way the “View Code” Button works — the default state is that the playgrounds are closed. You could change this (just for your checking process) to have the playgrounds open by default and then just scan each page. I think that could be a small step in the right direction.

TejasQ avatar Jun 23 '19 16:06 TejasQ

Let me know if you want to take it so I can mark it as taken.

TejasQ avatar Jun 23 '19 16:06 TejasQ

Let's not mark it yet! If this is not taken by next Friday I will pick it up :)

ddc22 avatar Jun 23 '19 16:06 ddc22

@TejasQ I'd like to take this issue.

bradd123 avatar Jun 23 '19 18:06 bradd123

You got it, @bradd123!

TejasQ avatar Jun 23 '19 19:06 TejasQ

@TejasQ I made an initial commit fixing hooks examples. Please take a look. I will fix others tomorrow.

bradd123 avatar Jun 23 '19 19:06 bradd123

Pushed some more changes. Currently, there are 9 pending components. I will fix them ASAP.

bradd123 avatar Jun 28 '19 08:06 bradd123

I've been sick for the last week, will resume working on it.

bradd123 avatar Jul 07 '19 07:07 bradd123

Nice!

TejasQ avatar Jul 08 '19 09:07 TejasQ