Live data from Hacker News

Show HN: OverType – A Markdown WYSIWYG editor that's just a textarea

news.ycombinator.com

91–100 of 102 posts

Re: Show HN: OverType – A Markdown WYSIWYG editor that's just a textarea

#91
post #72

If it were a WYSIWYG editor, there'd be previews for images. But it seems like it's just syntax highlighting for textareas. Nice project either way, but false advertising.

I can type text, mark it, click "B" for bold and it works. This is WYSIWYG minus images.

You see _ text _, but instead of 2 underscores you get formatted text. That's a definitional violation of WYSIWYG editing style

Re: Show HN: OverType – A Markdown WYSIWYG editor that's just a textarea

#93
This is really cool! Thanks for sharing your work. As a live Markdown styler, it's beautiful and quite well done.

My life-long gripe is that Microsoft Word forms the basis for what people think text editing is and should be. This could be incredibly useful for developers though.

Re: Show HN: OverType – A Markdown WYSIWYG editor that's just a textarea

#94
Calling it WYSIWYG is a misnomer: this is just syntax highlighting, it just so happens that the highlighting styles agree to an extent with the final rendering. And the idea is not exactly new: https://mediawiki.org/wiki/User:Remember_the_dot/Syntax_high...

Two issues I saw:

- on my phone, the framerate noticeably drops as I scroll over the widget

- caret positioning within the textarea seems to desync against the letter positions in the highlighted div

And the whole concept severely constrains the styling choices that could be applied to the highlighted output, but I suppose that was a given.

Re: Show HN: OverType – A Markdown WYSIWYG editor that's just a textarea

#95
Well, Highlight API ( https://developer.mozilla.org/en-US/docs/Web/API/Highlight ) should just work inside too.

At least it works in my Sciter like this:

    
      textarea::mark(myHighlight) {
        background-color: yellow;
        color: red;
      }
    
    
       Lorem ipsum dolor sit amet
    
    

      // Select a range of text to highlight
      const range = document.createRange();
      const textNode = document.querySelector('textarea').firstChild; 

      range.setStart(textNode, 6); // Start at the 6th character
      range.setEnd(textNode, 11); // End at the 11th character

      // Highlight the range
      range.highlight("myHighlight")

    
Ask your browser vendor to enable highlight API in too :) so such tricks will not be required.

Re: Show HN: OverType – A Markdown WYSIWYG editor that's just a textarea

#96
post #72

Earlier quoted context omitted.

I can type text, mark it, click "B" for bold and it works. This is WYSIWYG minus images.

WYSIWYG does not refer to the icons in the toolbar, but rather the text itself. This is not WYSIWYG because when I make something bold, I see a bunch of asterisks around it. Still a cool project, but someone who does not understand markdown would wonder why pressing the heading button makes my text into a hashtag instead of making it bigger.

I see both. It's bold and has asterisks around the bolded text.
Post reply on HN