Thu, Apr 30, 2020Terminal Links
Terminals make it hard to copy things: Selecting text works differently to what people are used to, and ^C aborts the current program. Links are hard to use. Now you can click on links in the repl.it terminal. It's as simple as starting a repl and printing a URL to the terminal. This is super helpful with languages like Rust, which often print URLs in error messages to help you debug and learn.
Tue, Apr 28, 2020Improving Repl.it's Mobile UX
I like the process of writing because of how simple and portable the tools are. Regardless of time or place, a way to write things down is never far away. There's very little friction between inspiration and experimentation. I wish writing code was more like this. In fact, Repl.it is great for quickly experimenting with coding ideas. I can open a tab in my browser and start coding as fast as I can start writing an email. But what if I’m not near my computer? While Repl.it has always worked on phones, it was never optimized for it. That's why we're excited to release our first iteration of a mobile interface! Here's a quick look at running a Go http server using one of our templates: Rather than trying to adapt our desktop layout to a smaller screen we’re building this with native mobile design patterns in mind. We added a tab bar to the bottom of the screen. It acts as the primary navigation for the IDE similar to how native mobile apps do.
Tue, Apr 14, 2020Terminal Search
When you're deep into a debugging session printing a bunch of here, there, and wat, the output in the terminal can get hard to read. That's when search comes in handy, and that's why we're excited to announce our new terminal search functionality. You can get to it via the small search icon on the top-right corner of the terminal: And here it is in real-life action from one of a recent debugging session:
Tue, Mar 24, 2020Packaging Support for Java - Try Maven Packages in Your Browser
Java is one of the most popular languages on Repl.it, and the JVM powers many of our other languages (Java Swing, Clojure, Kotlin). We want to make it as easy as possible to code with other people and build new programs out of programs that already exist. So we've added packaging support for Java! The Universal Package Manager now understands how to add and remove Java packages using Maven. It also can search the Maven central repository for packages. If you'd like to get familiar with the Java ecosystem, I highly recommend Andreas Kull's Awesome Java list. It was while scrolling through this list that I found Yasser Ganjisaffar 's crawler4j, a web-crawling library. Building something with Java + Packages To show you how powerful Java Maven packages could be, we're going to build an app to pull down the most interesting Twitter threads. To start, I made a new Java repl, searched for crawler4j, selected the edu.uci.ics:crawler4j package, added it, copy-pasted the quickstart example in crawler4j's README, and clicked "run." It started crawling the UCI computer science home page. That's not quite what I wanted, so I pointed the crawler at the Threader front page, to see if I could pull down some interesting Twitter threads. Thanks to Yasser's well-documented examples I soon had a directory of popular threads.
Wed, Mar 4, 2020CLUI: Building a Graphical Command Line
“Command line interfaces. Once that was all we had. Then they disappeared, replaced by what we thought was a great advance: GUIs. GUIs were - and still are - valuable, but they fail to scale to the demands of today's systems. So now command line interfaces are back again, hiding under the name of search. Now you see them, now you don't. Now you see them again. And they will get better and better with time: mark my words, that is my prediction for the future of interfaces.” [1] Don Norman wrote this in 2008. Since then, search has become more powerful and users have grown more dependent on it-- searching for information with context-aware autocomplete is present in almost every popular digital product. Traditional CLIs, however, were never widely adopted by end-users because of their learning curve. Terminals, the primary platform for command-lines, are intimidating and feel like a black box to non-technical people. Also, a text-only interface is limiting-- it only allows actions to take place through language instead of the clicks, taps, and hovers that we’re used to today. Commands and flags often have obscure names, and spelling mistakes can result in cryptic errors, or worse, doing something you didn't intend. Despite all these problems, CLIs are still powerful. The input mechanism is always the same: text. It’s predictable and constant. Adding more commands takes minimal effort from the developer. Users aren’t overwhelmed with information-- you just specify the exact commands you need at any given moment. These benefits, however, come with the tradeoff that commands must be memorized to be efficient. Today, GUIs are the most popular user interface paradigm because they address many of the concerns above. They use visual metaphors for everyday objects we are used to: desktops, windows, tabs, buttons, menus, files, and folders. They’re intuitive and offer a small learning curve to perform basic actions, like moving files via drag and drop. It’s faster to recognize an icon than to remember the action’s name. The benefits of GUIs are rooted in both memory recognition, which “...refers to our ability to “recognize” an event or piece of information as being familiar”, and memory recall, which “...designates the retrieval of related details from memory.” [4, 5] So GUIs are obviously the best UI paradigm ever, right? Probably not. Although GUIs might solve some core usability issues that most CLIs present, they "...fail to scale to the demands of today's systems" [2, 3]. The moment you want to add a feature to a GUI, there’s an immediate question about where to put that feature. Should it be in the top right? Bottom left? Nav bar? Behind a tab? In the sidebar? Revealed on hover?
Wed, Sep 18, 2019Making Repl.it Collaborative at Heart
Coding, people believed, was an activity hackers did alone. While that might have been true in the past, the world is changing. New programmers come online every day and they want to effortlessly work and interact with others while writing code. Yet collaborative coding environments have remained troublesome to setup. Last year we launched Multiplayer, our real-time collaborative system, in beta. We’ve learned a lot since then. We’ve learned that while real-time coding is useful and fun, asynchronous collaboration is important for users working on long-term projects (which people are increasingly doing on Repl.it). We’ve learned that Multiplayer needs to be a core feature of the product -- not something you “turn on.” This meant a redesign of our core protocol and infrastructure to make it collaborative at heart. Repl.it is now natively Multiplayer: Collaborators can code together at the same time or asynchronously, real time editing is more robust, and every IDE feature works seamlessly in a collaborative setting. Protocol Changes & Operational Transformation The major challenge in making Repl.it collaborative at heart was adapting all our existing functionality to work seamlessly in a multiplayer environment. For a very long time we’ve gotten away with keeping the protocol very simple. Modeled after the Read-Eval-Print-Loop with a strict state machine. Only one action could be processed at a time and had to run to completion.
Wed, Mar 20, 2019Repl.it GFX: Native graphics development in the browser
At Repl.it we live and breathe making software creation easier. With our programming environment, you could start coding in your favorite language in seconds. With live deployments, we made web hosting a breeze. With Multiplayer, we've removed the drudgery from coding with friends. And today, we're excited to bring native GUI applications and game development to the browser. Before we go on, you have to see this in action: Just run the repl below, wait a few seconds for it to load, focus on the output window and start playing Tetris in Pygame: Let's take it up a notch and boot up this nifty desktop app we all love (might take up to a minute to load but then can be done recursively):
Thu, Dec 6, 2018Repl.it Multiplayer
Today we're announcing the most-significant evolution of our platform — something we've been building towards for a long time that we're thrilled to share with you. Introducing Multiplayer: code with friends in the same editor, execute programs in the same interpreter, interact with the same terminal, chat in the IDE, edit files and share the same system resources, and ship applications from the same interface! We've redesigned every part of our infrastructure to work in multiplayer mode -- from the filesystem to the interpreter. This works with all the languages that work on Repl.it. All free and ready for you to use right now. All you have to do is login, create a repl, start a Multiplayer session, give a link to your friends, wait for them to join, and start hacking! We started beta-testing Multiplayer last month. And while we think we're merely scratching the surface in terms of what can be done with it, a walkthrough of some of the emergent use-cases will give you an idea of how it works and how you can use it at your work, school, or for your side-project: Help
Tue, Oct 16, 2018File Switcher
A few days ago we shipped a simple feature that will save our users time in finding and opening files, especially for larger projects. This can even be used without having the file tree visible. Read on to see how to use it and to see a demonstration. If you've used offline IDE's before then you're probably familiar with this feature. To bring up the file switcher you can hit ctrl + P (cmd for mac), incase you're wondering why we chose that binding, it's cause it's the default for most modern editors. I'm actually interested in the history behind this feature, who started it, and why in the world did they pick ctrl + P (maybe it was meant for command pallete?), if you know you can reach out to me on twitter @masad-frost. Once you're in the file switcher you can type your file name or full path and it will show you your file, it also supports fuzzy string matching, so can just type part of the file you're looking for and it should show up.
Thu, Jul 19, 2018Universal Package Manager
Open-source has revolutionized software development -- it wouldn't be an overstatement to say that it's been the most significant productivity win for developers in the last decade or so. At Repl.it, our goal is to make programming more accessible and what better way to do that than make available to programmers the entirety of open-source packages available at their fingertips. Today we're excited to announce our Universal Package Manager -- the Repl.it package manager that will grow to support every language on our platform. We're now starting with JavaScript, Python, HTML/CSS/JS, and the web frameworks that we support. We've had basic support for automatic package detection and installation for a while now, but what changed is that we support search and spec files (package.json, gemfile, requirements.txt, etc) across the board. Furthermore, where we used to write custom code for every language that we support, now we merely add fields to a config file. This was mad possible by creating a common package manager runner abstractions. Adding package manager support for a language is as easy as adding a couple of fields in a JSON config: In addition to this we have a more ambitious project in the works to build the same package manager that works across all languages (with the same semantics). You should come work with us.
Sun, Jul 1, 2018Zero Setup VSCode Intelligence
At Repl.it our goal is to provide state of the art in developer tools to everyone in the world, for free. When we started moving our product beyond a simple REPL and started adding IDE features, we had to invent standards and wrappers around every language tool for our frontend to consume. For every editor feature, say errors and warnings (linting), we had to extend our development protocol with a set of commands and data structures, and then teach our development containers how to wrap the given tool, say Pylint, and our frontend on how to consume it (say annotate the editor with errors and warnings). A similar thing has been happening with IDEs for the past few decades -- every editor had to come up with their in-house ad-hoc protocol, and every tool developer had to build adapters and wrappers for editors to consume. However, this is about to change: a couple of years ago, Microsoft's VS Code team announced "A Common Protocol for Languages", a single all-encompassing protocol that provides general-purpose language tooling -- be it refactoring, code-completion, or errors and warnings -- all implemented once and then seamlessly plugged into any editor that understands this protocol — this was dubbed the "Language Server Protocol" (LSP). In addition to LSP, VS Code also open-sourced the editor that powers VS Code: Monaco. Monaco is an editor built with web technologies, and since we started looking at LSP a few months ago, it only made sense for us to transition to Monaco first. Even before the introduction of LSP on Repl.it, Monaco allowed us to provide some cool language features (Smart Autocomplete, Go to Definition, Find References) for TypeScript and JavaScript because they're bundled with the editor. On top of that, the editor has a slick feel to it. In this release, we're rolling out language servers for Python (2, 3 and Django), C, C++, and ReasonML. And soon we'll be adding support for more languages -- Java and Ruby are looking to be next in line. Let's run through some of the features: Autocomplete and signatures
Wed, Jun 13, 2018React Framework Preboot
Two days ago we introduced our beta support for React frameworks, ranging from static-site generators like GatsbyJS, to fullstack frameworks like Next.js. Today we're launching a significant performance enhancement that we're calling preboot. Whenever you land on a repl, you get a container to develop against. Our containers are generic and work for any language/framework. When you land on a React framework, you had to hit "run" to start the server (it basically sends a yarn develop or similar to the container) . The container manager will then detect an open port, send an event to the IDE, which will show you a webview (speeded up gif below) -- afterward, you're on your way building your app. However, this kind of experience is suboptimal because it's slow. We pride ourselves on setting up the development environment within 2 seconds of selecting a language/framework so, naturally, we need to do better. Luckily, we have previously implemented a pooling mechanism on our infrastructure so that containers are ready and hot when you need them. What was missing from that is custom "boot" command that gets the container really hot, listening on a port, and ready to start serving. So now, when you land on a React framework environment, we grab a container for you that's already running -- your repl IDE will simply attach to it. Take a look:
Thu, Jun 7, 2018Repl.it ❤️ React
Despite the negative press covfefe around React.js when it first came out, I instantly fell in love with it. The thing I liked the most about it was the component model. Until then the JavaScript community has been trying for years to come up with the correct abstraction for creating reusable modules, but it was always leaky. Because React components are essentially functions, and because functions are the undisputed champion of reusable code, it worked out extraordinarily well. You don't need dependency-injection, or any other modularity hacks, you simply pass props! Also, the virtual dom made it so that components are, by default, protected from other components prying into their internals. That's just one aspect of what made me love React and it was a significant factor in me applying to work for Facebook in 2013. After I got in, I worked tirelessly to join the team behind React.js, and in early 2014 I was able to do so, and my first task was to build the React Native packager and CLI. When we launched React Native in 2015, you could just run a single command, and you'd have the entire development environment setup. Developers were so thrilled with this, that some tweeted out the command. I learned that when you make things easier, you get a lot more people through the door. So when Haya and I started Repl.it we wanted to go further than zero-config quick-starts and build a platform where you can code in any language, any framework, from anywhere. We initialy focused on education because we thought that teachers and students are underserved by the tech community. However, now that we're in 15% of US schools and growing worldwide, our technology has tranceded the education use-case, and we have an growing community of developers using Repl.it to build and deploy apps. Much of our work is supported by innovations from the React community (our apps are built with React, our IDE plugin system is inspired by Redux, etc.) so now we want to leverage our platform to give back to the community. We want to build easy and accessible tools for you to use. You can use it for developing apps, to debug libraries, or for prototyping. Furthermore, we want help spread the React technology by making it easier for outsiders and underserved communities to learn and participate in the larger developer ecosystem. Today we're excited to announce that you can try, build, and deploy fullstack React apps starting with a few of our favorite React frameworks. Before I go on, just want to note that this is a public beta release (it literary came out today) and we'll be iterating heavily on it for the next couple of months and we rely on your feedback to make it better.
Tue, Mar 13, 2018Repl.it: the IDE That Grows—from Playgrounds to Fullstack Apps
At Repl.it we come to work every day to explore a single idea—what if programming just worked? What if instead of fiddling around with packages, configurations, and mismatching versions, you just open your IDE and start coding. What if developers can go from an idea to coding and shipping software with no time in between. What if teachers who want to teach programming don't have to also work as IT administrators. What if students can just code their homework without having to set up the development environment on every computer they wanted to code on. There exists an inverse relationship between developer tool sophistication and the getting started step. In other words, the more sophisticated our tools are, the harder it is to set up. Some would go as far as to say that programming is getting harder to learn. Given that progress in programming and developer tools will continue we have to actively fight back against the ever-increasing complexity of setting up the dev environment. Online coding playgrounds solve part of the problem by getting people to code as soon as possible. They're pre-setup environments that make a lot of decisions for you. They make it easy to get started, to learn to code, and maybe even prototype simple apps. However, up until now, they lacked universality which is key to computing. In other words, you can only use one language, maybe a few frameworks but you're often limited by what you can do. Today, we're changing this. We want the best of both worlds, an IDE that starts out looking like a playground but can grow with you as soon as you require the extra power. Here is how the IDE can grow from a simple Read-Eval-Print-Loop to a full-stack application development environment: Repl.it will always start out as a simple REPL, with a single file editor and a console. You hit run, a new environment is created, your editor script is evaluated, and then you can interact with the result in the console. If you want to use files, write to files, split your code into modules, etc., you just do that and behinds the scenes the environment will switch to one where you're interacting with the filesystem. Your code will start to compile and run as you'd expect it when you run a project.
Mon, Mar 12, 2018Live Server Development and Deployment (Beta)
Repl.it is becoming the platform where developers come to learn and build. With web hosting we also made it possible to host websites and since then we've seen an explosion of websites hosted on Repl.it. Today we're going further by making it possible to deploy servers on Repl.it. Just open a port, run your code, and that's it, it's deployed! For our 90s website competition I built this socket.io-based chat hosted on Repl.it: 90s-chat--amasad.repl.co Here is the repl for it:

