Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Load exercises from a repo in addition to gists #1096

Closed
RedBrogdon opened this issue Jun 5, 2019 · 5 comments
Closed

Load exercises from a repo in addition to gists #1096

RedBrogdon opened this issue Jun 5, 2019 · 5 comments
Assignees
Labels
closed-duplicate Closed in favor of an existing report P1 A high priority bug; for example, a single project is unusable or has many test failures type-enhancement A request for a change that isn't a bug
Milestone

Comments

@RedBrogdon
Copy link
Contributor

This involves a few individual tasks:

  • Create a format for storing multiple DartPad exercises in a single repo.
  • Add a RepoController or something similar to dart-pad that's capable of loading data from a repo set up with that format
  • Update the new embed UI and playground UI with query string parameters and have them use the RepoController to fetch and parse exercises when supplied with those parameters.

q.v. GitHub's API docs for retrieving repo contents: https://developer.github.com/v3/repos/contents/

@RedBrogdon RedBrogdon added the type-enhancement A request for a change that isn't a bug label Jun 5, 2019
@RedBrogdon RedBrogdon added this to the Backlog milestone Jun 5, 2019
@RedBrogdon RedBrogdon added the P1 A high priority bug; for example, a single project is unusable or has many test failures label Jun 5, 2019
@kwalrath
Copy link

kwalrath commented Aug 2, 2019

Would it be possible to load code from part of a doc repo? I'd love to be able to host DartPad code under https://github.com/dart-lang/site-www/tree/master/examples, so that our site tests can detect when the DartPad code needs to be updated.

@RedBrogdon
Copy link
Contributor Author

Fixed for the new embeds by #1295.

@rrousselGit
Copy link

Fixed for the new embeds by #1295.

Does that mean this is done?
If so, how can we use it?

I would like to embed dart-pad in a blog-post. But having to maintain gists is a hassle, and feels off when the article is written in markdown

@RedBrogdon
Copy link
Contributor Author

I should have linked everybody to the wiki page we have for this:

https://github.com/dart-lang/dart-pad/wiki/Embedding-Guide#query-parameters

There are a number of ways to get code into an embedded editor. @johnpryan wrote a script that can detect and transform markdown blocks into iframes, and it's possible to load directly from a repo by creating a small metadata file for each exercise you want to load.

One feature we still haven't implemented is a hardcoded GitHub path to a single file. That feature request remains outstanding.

johnpryan pushed a commit to johnpryan/dart-pad that referenced this issue Jun 27, 2023
Bumps [protobuf](https://github.com/google/protobuf.dart) from 2.1.0 to 3.0.0.
- [Release notes](https://github.com/google/protobuf.dart/releases)
- [Commits](google/protobuf.dart@protobuf-v2.1.0...protobuf-v3.0.0)

---
updated-dependencies:
- dependency-name: protobuf
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
@parlough
Copy link
Member

parlough commented May 6, 2024

Closing this as a duplicate of #1763."

Note that the workshop feature discussed in that issue is no longer supported. Feel free to explore other open issues like #2702 that explore alternatives.

@parlough parlough closed this as not planned Won't fix, can't repro, duplicate, stale May 6, 2024
@parlough parlough added the closed-duplicate Closed in favor of an existing report label May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed-duplicate Closed in favor of an existing report P1 A high priority bug; for example, a single project is unusable or has many test failures type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

No branches or pull requests

4 participants