Feature: Mark editable regions on help posts in forum
See original GitHub issueDescribe the Issue
The forum help posts submitted by users do not show the editable parts of the code. The snippets (‘you code so far’) have boilerplate code which makes it difficult to understand the actual edits made by the user.
Steps to Reproduce
-
On any later step in the RWD project, click Ask For Help and look at the forum post contents.
-
The code snippet looks like so:
<html> <body> <main> <h1>CatPhotoApp</h1> <h2>Cat Photos</h2> <!-- TODO: Add link to cat photos --> <p>Click here to view more <a href="https://freecatphotoapp.com">this is what I changed</a>.</p> <img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" alt="A cute orange cat lying on its back."> </main> </body> </html>
Expected behavior
Instead of the above, maybe the code snippet should show what they changed:
<html>
<body>
<main>
<h1>CatPhotoApp</h1>
<h2>Cat Photos</h2>
<!-- TODO: Add link to cat photos -->
<!-- User Editable Region -->
<p>Click here to view more <a href="https://freecatphotoapp.com">this is what I changed</a>.</p>
<!-- User Editable Region -->
<img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" alt="A cute orange cat lying on its back.">
</main>
</body>
</html>
Maybe a nice to have will be to show some diff-style syntax highlighting, but the above should be a good starting point.
Issue Analytics
- State:
- Created a year ago
- Comments:26 (22 by maintainers)
Top Results From Across the Web
Discussion Boards - Blackboard Student Support - UA Little ...
A Forum is an area where a topic or a group of related topics are discussed. For each Forum, the page displays the...
Read more >Frequently Asked Questions – WordPress.org Forums
Forum moderators can mark any post resolved. Plugin and theme developers can mark posts resolved in their specific forum areas. They should have ......
Read more >Allow changes to parts of a protected document
Use Restrict Editing to protect parts that can or can't be changed, who can make changes, find areas you can edit, or unlock...
Read more >Users Forum Help - The Chicago Manual of Style
(To access a list of your previous posts, please see these instructions.) To delete the post, click on the “edit” button, then check...
Read more >Quickstart for GitHub Discussions
On GitHub.com, navigate to the main page of the repository. · Under your repository name, click Settings. · Under "Features", click Set up...
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 FreeTop 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
Top GitHub Comments
The editor knows where the editable regions are, so we could probably include the
--fcc-editable-region--
markers in the forum post. 🤔What about just using a diff view? I will make a quick mock: https://forum.freecodecamp.org/t/forum-diff-mock/516258
Ideally, we could use a package like diff to get even more detailed output (only show the changed characters)