Preventing front matter and custom syntax from rendering in WYSIWYG mode
See original GitHub issueSummary
The Toast UI Editor is awesome and we’ve begun to use it at GitLab. I’m currently exploring options for how we can prevent certain portions of a source file from being edited in WYSIWYG mode. For example:
- Simple = raw markdown file (.md solved automatically)
- Complex = mixed languages (.html.md.erb example here)
Context
You can view additional context in this issue but I’m currently under the impression that a custom HTML renderer is the way to go.
Questions
- Do any approaches other than the custom HTML renderer come to mind?
- I’d imagine preventing frontmatter from being edited in the WYSIWYG mode would be a common expectation. Do you know of an existing solution or custom HTML renderer that prevents frontmatter from rendering in WYSIWYG mode?
- Can you point us to any existing open source custom HTML renderers that others have created? These would be great learning resources and/or jump-off points.
Thank you
Thank you in advance for any feedback and hopefully we can contribute back to Toast UI Editor as we make progress. For example if #2 above doesn’t exist already, I’d imagine others would find such a custom renderer useful.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:3
- Comments:13 (7 by maintainers)
Top Results From Across the Web
Display non-markdown content in the WYSIWYG mode of the ...
The goal is to prevent editing of frontmatter in the WYSIWYG editor. Short term ideas. Pre-parse and remove from editing completely then stitch- ......
Read more >README_en_US.md · Vanessa/vditor - Gitee.com
Introduction; 🗺️ Background; ✨ Features; Editing Modes. WYSIWYG; Instant Rendering; Split View. Syntax support; Showcases; 🛠️ User Guide.
Read more >Full-featured WYSIWYG Markdown Editor - tui.editor | CSS Script
All possible options & functions to customize the WYSIWYG Markdown ... custom HTML sanitizer; frontMatter: whether use the front matter.
Read more >WYSIWYG / Rich Text Editor | Jira Server and Data Center
JRASERVER-62350 - Support for custom macros in Rich Text Editor. Suggestion ... It says it "Provides a wysiwyg textarea renderer using the TinyMCE...
Read more >Updates | Front Matter
Updated JSON schema link to supported version by VS Code (draft-07); Hide the view mode action from the Front Matter panel if no...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

@derek-knox Sorry for late replying. We are planning to develop our front-matter
pluginoroptionand start to develop today as below.toastmark).Additional, We consider only the
yamlformat as below.Thank you!
@derek-knox We added
frontMatteroption(#1171) and release it inv2.4.0.I will explain about a few things as below.
gfm.customTypeprop using our custom parser.Additionally, there are some issues that cannot be implemented in our current structure such as markdown custom syntax and exact synchronization between WYSIWYG and Markdown. And front matter option needs supplement(syntax highlighting, internal logic for switching to WYSIWYG). To solve these problems, we are currently planning to rebuild the editor completely in the next major version and are already in progress. I will register the related information on next week, so if you are interested, please give me your opinion! Thank you 😃