Skip to content
This repository has been archived by the owner on Jun 23, 2018. It is now read-only.

Embeddable repl #127

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

joelmccracken
Copy link
Contributor

Woot! So, this is ugly, gross, and has many things wrong with it, but it seems to be working, which is what I want for now.

I could use some advice on code structure and organization; I basically did the minimum necessary to make things work.

Thanks.

Edit: Addresses #7

@amasad
Copy link
Contributor

amasad commented Dec 18, 2014

nice hack! I think the design/interaction of an embedded session should be re-worked. Horizontal splitting of editor and console will not really work since it's safe to assume that websites embedding this will have a smaller width than the full screen repl.it. The average website content width -- I would guess -- is around the 700px.

Additionally, I think the main interaction we should support is the most basic one: "Run the code". Most people that I talked to that wants to embed the code are mostly interested in "runnable" code. So the most prominent part should be the editor and the console should show up only when the code runs. Of course, there would be a link back to repl.it to edit the code.

Thoughts?

@joelmccracken
Copy link
Contributor Author

Those are good points. What do you think about merging this in soonish
and disabling the functionality with a feature flag? I'm
afraid that it will take me some time to make this functionality to
work, and long-running PRs may become a problem.

Regarding screen width, this is a great point. I think I want to
modify the embedded testing html page with multiple iframes with
different widths. That way, we can test different use cases.

Also, I'm fine with "run" being the main use case. My main goal
with Replit is to use it in blog posts and be able to show code & show
it running. I would also like users to be able to edit the code and
experiment with it, but having to view an external website would make
sense.

What do you think about having a button that toggles between showing
the editor and showing a console? I kinda think that makes sense,
since we need to show both things, anyway.

@amasad
Copy link
Contributor

amasad commented Dec 18, 2014

All that sounds good. Can you make it safe to pull. i.e. disabled behind a flag so users don't see it for now

font-size: 75%;
}


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

extra space here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh yeah, I meant to suggest using a feature flag. Will add one soon.

On Thu, Dec 18, 2014 at 3:09 PM, Amjad Masad [email protected]
wrote:

In css/style.css
#127 (diff):

@@ -1171,6 +1178,13 @@ and (max-device-width : 480px) {
font-size: 75%;
}

+#save-box a {

  • color: #0E157F;
  • text-decoration: none;
  • font-size: 75%;
    +}

extra space here


Reply to this email directly or view it on GitHub
https://github.com/replit/repl.it/pull/127/files#r22067666.

@joelmccracken
Copy link
Contributor Author

I'm in the middle of setting up the feature flag code. I'm thinking that I will want to have a deploy of this code for myself. What would I need to do to create an actual public facing deployment?

@joelmccracken
Copy link
Contributor Author

Since the model of this project is changing, I'm not going to work on this anymore. But, I will leave this open in case anyone wants to pick up where I left off (or @amasad you can close it if you'd like)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants