Skip to content

Commit

Permalink
fix: improve bookmarklet functionality for GitHub notebook URLs (#3400)
Browse files Browse the repository at this point in the history
  • Loading branch information
Haleshot authored Jan 11, 2025
1 parent 3214e5f commit ccf3a19
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions docs/guides/publishing/playground.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,13 +59,13 @@ navigate to `https://marimo.app/path/to/notebook.py`. For example:
For a convenient way to create notebooks from GitHub, drag and drop the
following button to your bookmarks bar:

<a href="javascript:(function(){let url=window.location.href.replace(/^https:\/\//,'');window.open('https://marimo.app/' + url, '_blank');})();"
<a href="javascript:(function(){if(!location.href.endsWith('.py')&&!location.href.endsWith('.ipynb')){alert('Please use this bookmarklet on a URL ending with .py or .ipynb');return;}let url=window.location.href.replace(/^https:\/\//,'');window.open('https://marimo.app/' + url, '_blank');})();"
style="padding: 5px 10px; background-color: #007bff; color: white; text-decoration: none; border-radius: 5px; font-weight: bold;">
Open in marimo
</a>

Clicking the bookmark when you are viewing a notebook in GitHub will
open it in marimo.app.
Clicking the bookmark when you are viewing a notebook will
open it in [marimo.app](https://marimo.app/).

!!! note "From Jupyter notebooks"

Expand Down

0 comments on commit ccf3a19

Please sign in to comment.