Often in programming discussion, we share code snippets with each other using sites like ideone.com or pastie.org.

The chat already has cool previewing features that show the contents of a link of any image on any site, a Wikipedia article, a StackExchange question, etc.

Can chat fetch and preview the first few lines of code from a link to one of these popular sites?

Another unique feature is that the preview can contain the result of running the code, which can save a good bit of time.

Related: What sites should have hyperlinking (onebox) support in chat?

  • 1
    Downvoter: This isn't a vote on the proposal; the vote button's label says "this shows research effort; it is useful and clear." Please clarify if I don't meet those criteria. – Potatoswatter Jun 10 '11 at 9:15
  • 4
    I'm not the downvoter, but on meta a downvote can mean that the person just doesn't agree with what you are saying. – JohnP Jun 10 '11 at 9:27

Can't say I'm keen on this. I come across so many questions where the pastie/pastebin link is already dead leaving the question somewhat broken. I'd far rather people post code snippets in their question and link to a pastebin or jsfiddle only when they absolutely have to.

Supporting pastie/pastebin previews in chat is likely to encourage misuse of off-site links.

  • 1
    1. ideone posts never seem to die. (I thought pastie was the same too.) 2. Chat is very different from question pages, and the primary usage I'm speaking of is not purposely posing or definitively answering questions, but rather back-and-forth debate. – Potatoswatter Jun 10 '11 at 9:12
  • 1
    True, chat is different, but once people get an idea in their head: "oh I can pastie on chat, I'll pastie my questions as well". Feels like a gateway drug :) – Kev Jun 10 '11 at 9:15
  • 1
    The problem I've seen with pastie'd questions is that the OP is just too lazy to trim the irrelevant parts. Excessively long pasties would have useless previews, and if the text is short, a user has every incentive to post the text inline. (ideone runs your code as well, so it is a complementary service. Indeed that is the main reason we use it in lounge<C++>; merely sharing text is not a motivation.) – Potatoswatter Jun 10 '11 at 9:27

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .