mdn / mdn/fred

Create short static sharable links in Playground

Open
#973 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
233
Forks
61
Avg merge
1d 1h
Merged PRs (30d)
82

Description

https://github.com/user-attachments/assets/b5e7e75a-6514-4d87-acab-6824a0d79b7d

If the code isn't modified, present the same share link when the share box is opened. Also, if only whitespace modifications are done then don't create a new link. The best option would be to format the code before creating share links, and don't create a new link if the code remains the same.

I often create and copy a share link and forget about it. Then when I try to retrieve the link again the share box asks me to create a new one.

Fixing this will reduce some load on the server. Also, users will be able to get the same link quickly.


Also can we make shorter links that are easy to share, e.g. jsfiddle.net/z0mtwjs1/

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the Playground share box and the code that creates share links. Check how code changes are compared, including whitespace-only edits, and how links are stored or retrieved. Done means unchanged or whitespace-only code reuses the existing link and the requested shorter-link behavior is addressed.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend, web-dev
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.