Default action for .md files

I consider the preview of the markdown to be the essential part for new users opening a markdown file, and not the markdown editor. The current default is to open the markdown editor though.

I’m thinking that if one knows that one wants to edit, one has probably committed a bit to the action and wants a preview open anyhow along side working with it. Also, if you are working with the file that you know you want to edit, you are probably having more experience and will be able to find it, perhaps you even realized that should be edited due to viewing the preview first. Also, if you are a new users, you will be afraid of the file if opened in editor view but not afraid of it if opened in the preview view.

So, what do you think? Does it make sense to change the default to be in preview mode?

3 Likes

If it is one more click on a button to edit it, sure – also in line with GitHub then.

Interesting point, so basically you’re saying

“If I don’t know what a markdown file is and I double-click an .md file, then if I see the raw text I’ll be confused, if I see the rendered text then I’ll be less-confused”

And

“If I know how to write markdown, if I see rendered text I will not be confused, and I’ll know to find the ‘edit’ button if I want to edit the text?”

1 Like

Another thought - I quite like the hackmd approach of having a few visual buttons as cues for quickly switching between viewing / writing:

image

perhaps we could use something similar for the markdown editor in JupyterLab, since this is a familiar pattern for people already.

2 Likes

@choldgraf excellent summary - yes! I like your idea to consider making a split view possible as well.

2 Likes

We could even go one step further: only display a WYSIWYG editor for markdown files (and markdown cells).

With an option to switch back to the current “hacker mode” for writing formatted by writing markdown by hand :slight_smile:

2 Likes

WYSIWYG with markdown would be awesome…looks like jupyterlab can use react as well, so perhaps draft.js could be straightforward as a plugin (https://jupyterlab.readthedocs.io/en/stable/developer/virtualdom.html)

There was another project that did full WYSIWYG editing (https://github.com/genepattern/jupyter-wysiwyg) but it output HTML instead of markdown under-the-hood

1 Like

Hi everyone! I’m here as part of a google to try to figure out how to view a rendered markdown file. I’m sure I’ll find that answer in my search (I’ve done it before! I just can’t remember where the button is!!) but I figured I’d comment to say that I really like the idea of split view by default if possible, or at least making the render button a little easier to find :sweat_smile:

No worries if this is a dead thread (Discourse is asking me if I really want to continue this old conversation). Thanks for all the great work and careful thought!

EDIT: For me of the future. Right click hovered over the markdown file and you’ll see the “Show markdown preview option”. Thanks to https://www.youtube.com/watch?v=eQsRlqK-z1c!!

1 Like