Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

docs update code markdown_editor #893

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

lizzy985
Copy link
Contributor

@lizzy985 lizzy985 commented Dec 2, 2024

No description provided.

@maartenbreddels maartenbreddels force-pushed the master branch 2 times, most recently from cded5b2 to 32af76f Compare December 20, 2024 12:52
@@ -36,12 +35,12 @@ def Page():
""".strip()

markdown_text, set_markdown_text = solara.use_state(markdown_initial)
with solara.HBox(grow=True) as main:
with solara.VBox():
with solara.Row(grow=True) as main:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Row doesn't accept grow as an argument.

Suggested change
with solara.Row(grow=True) as main:
with solara.Row() as main:

@@ -36,12 +35,12 @@ def Page():
""".strip()

markdown_text, set_markdown_text = solara.use_state(markdown_initial)
with solara.HBox(grow=True) as main:
with solara.VBox():
with solara.Row(grow=True) as main:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, I missed this last time, but the return main pattern can also be removed here.

Suggested change
with solara.Row(grow=True) as main:
with solara.Row(grow=True):

@@ -36,12 +35,12 @@ def Page():
""".strip()

markdown_text, set_markdown_text = solara.use_state(markdown_initial)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And I also now noticed that the use_state here can be replaced with use_reactive, and .value and .set can be used throughout.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants