{"id":21691345,"url":"https://github.com/just214/playground-plugin-challenges","last_synced_at":"2025-08-28T16:33:42.931Z","repository":{"id":44988123,"uuid":"243274172","full_name":"just214/playground-plugin-challenges","owner":"just214","description":"Turn your Gists into Interactive Coding Challenges in the TypeScript Playground.","archived":false,"fork":false,"pushed_at":"2023-01-05T08:22:13.000Z","size":30579,"stargazers_count":12,"open_issues_count":12,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-26T04:41:35.193Z","etag":null,"topics":["challenges","playground","plugin","typescript","typescript-challenges","typescript-playground-plugin"],"latest_commit_sha":null,"homepage":"http://www.typescriptlang.org/v2/play?install-plugin=playground-plugin-challenges","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/just214.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-02-26T13:51:43.000Z","updated_at":"2023-03-09T02:29:26.000Z","dependencies_parsed_at":"2023-02-03T20:16:17.343Z","dependency_job_id":null,"html_url":"https://github.com/just214/playground-plugin-challenges","commit_stats":null,"previous_names":["gojutin/playground-plugin-challenges"],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just214%2Fplayground-plugin-challenges","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just214%2Fplayground-plugin-challenges/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just214%2Fplayground-plugin-challenges/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just214%2Fplayground-plugin-challenges/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/just214","download_url":"https://codeload.github.com/just214/playground-plugin-challenges/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248550231,"owners_count":21122928,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["challenges","playground","plugin","typescript","typescript-challenges","typescript-playground-plugin"],"created_at":"2024-11-25T17:37:34.899Z","updated_at":"2025-04-12T09:44:05.765Z","avatar_url":"https://github.com/just214.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# playground-plugin-challenges\n\n#### Turn Your Gists into Interactive Coding Challenges in the TypeScript Playground.\n\n##### [Try it Out](http://www.typescriptlang.org/v2/play?install-plugin=playground-plugin-challenges)\n\n\u003cimg src=\"https://res.cloudinary.com/gojutin/image/upload/v1583169134/playground-plugin-challenges/about.gif\" alt=\"Demo GIF\" style=\"max-width: 90%; margin: 0 auto;\" /\u003e\n\nCreated with the [typescript-playground-plugin-react](https://github.com/gojutin/typescript-playground-plugin-react) template.\n\n## How To Create Your Own Challenges\n\nSign in to GitHub and go to `https://gist.github.com/YOUR_USER_NAME`.\n\nClick the `+` icon in the upper right hand corner to create a new Gist.\n\n The *Gist Description* will be the name of your challenge project.\n\n From here, you will create a markdown file (`.md`) for each challenge item that you would like to create. The name of the file does not matter other than the `.md` extension. The order of the challenge items will be based on the order of the markdown files.\n\nEach markdown file should consist of three parts:\n1. Front Matter (optional metadata)\n2. Starting Code Block (problem code)\n3. Ending Code Block (solution code)\n\n### **Front Matter**\n\nFront matter is metadata that you can provide to each challenge item to change the UI or behavior. \n\nThe options are as follows:\n\n| Name | Description|\n|--|--|\n|`title` |The title of the challenge item. Defaults to `Challenge #1`. |\n|`description`|A description of the challenge item displayed below the title.|\n|`hint`|If you provide a hint, a button will be displayed that allows the user to reveal the hint.|\n|`exclude`|A list of TypeScript types that the user is not allowed to use.  |\n\n**Example** \n\n```\n---\ntitle: Add Function\ndescription: A simple function that adds two numbers.\nhint: Think math.\nexclude: string any\n---\n```\n\n### **Starting Code**\nNext, you will supply the starting code by using a code block (triple backticks).\n\nThis code should be written like JavaScript and not contain any TypeScript annotations. \n\nIt will be the user's job to add the necessary TypeScript code to make the errors go away. \n\n**Example** \n\n````` \n```\nfunction add(a,b) {\n  return a + b;\n}\n```\n`````\n\n### **Ending Code**\nThis represents the corrected version of the starting code and should not result in any errors. \n\nThe user will be presented with a `Show Solution` button. Once clicked, the editor code will be replaced with the ending code, which should cause all errors to be resolved.\n\nErrors can result from one of three things:\n1. TypeScript compile errors\n2. Errors resulting from using types in the excluded list defined in the front matter.\n3. Any changes that deviate from the starting code.\n\nIf this ending code results in errors, the user won't be able to progress to the next question. It is recommended to double check your code each time with the plugin to ensure that there aren't errors in the ending code.\n\n**Example** \n\n````` \n```\nfunction add(a: number,b: number) {\n  return a + b;\n}\n```\n`````\n\n### **Full Example**\n\n`````\n---\ntitle: Add Function\ndescription: A simple function that adds two numbers.\nhint: Think math.\nexclude: string any\n---\n\n```\nfunction add(a,b) {\n  return a + b;\n}\n```\n\n```\nfunction add(a: number,b: number) {\n  return a + b;\n}\n```\n`````\n\n## Just Remember\n\n- It's one Gist per Challenge group and one markdown file per challenge item.\n- Each markdown file consists of 3 parts: **front matter**, **starting code block**, and **ending code block**.\n- Front matter is optional. The starting and ending code blocks are not.\n- The ending code is only used to show the user one possible solution. Their code is checked against the compiler errors and compiled source code. This means that their solution does **not** have to match your solution. It just has to pass the compiler check, front matter exclusion types, and match the original source once compiled.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjust214%2Fplayground-plugin-challenges","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjust214%2Fplayground-plugin-challenges","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjust214%2Fplayground-plugin-challenges/lists"}