# RedditJS rebuilt the Reddit web client on Backbone and Marionette

> RedditJS is a third-party reimplementation of the Reddit web interface written in Backbone and Marionette with RequireJS and Handlebars on the front end and an Express and Passport server behind it. It adds a client-side data cache, embed widgets for other sites, and is now known as js4.red.

**BenjaminAdams/RedditJS** — Reddit built with Backbone.js

- Repository: https://github.com/BenjaminAdams/RedditJS
- Stars: 535 · Forks: 49
- Language: JavaScript
- License: BSD-3-Clause
- Published: 2026-10-22 · Updated: 2026-10-22 · Language: en
- Canonical page: https://hysenlabs.com/projects/benjaminadams-redditjs

## What the project is, and what it became

The repository description is Reddit built with Backbone.js, and the README opens with two facts that reframe everything else. The first is that RedditJS uses spa-seo-renderer so search engines can crawl this single page app, which is the tell that this is a JavaScript client rather than a set of server-rendered pages. The second is that RedditJS is now known as js4.red, with the code that powered it described as the code behind that site, which appears to have been removed. So this is an archived-in-spirit project that is still open on GitHub. The README also explains the origin in the first person. The author rewrote reddit from the ground up using the javascript framework Backbone and the reddit API, and states that he believes this created a better user experience as well as additional features, with updates followed at the subreddit /r/redditjs. The licence is BSD-3-Clause and the last push to the repository was on 2026-05-18, with no GitHub releases.

## The feature list, most of which is caching

The README's feature list reads like a product spec, and one item explains the rest. The Data Cache means you only have to load up a subreddit once. Once the subreddit is loaded, it pulls the subreddit or single post from memory, and the stated benefit is for both Reddit's server and you, since you only fetch once. Unique Views lets you view an entire subreddit in a new way, with thumbnails only, full images, and a large grid mode. Then there is Do everything, meaning you can normally do on Reddit, almost everything: vote, save and hide posts, and comment, mail and search without refreshing the browser. The Bottom Bar shows all the posts from a subreddit on single post views, caching it for later use if not already in memory, and when not active it stays at only 20 percent visibility so you can hardly tell it is there. The Subreddit Explorer turns the top left subreddit dropdown into a list based on category, with about 1,000 subreddits listed. The rest are smaller: Custom CSS so a subreddit's own CSS and flair are used, Comment Links that expand images and YouTube videos fullsize on hover, Permalink Comments that show a linked comment first plus the rest of the thread, keyboard navigation with the left and right arrow keys, Download Images that compresses images into a zip entirely on the client side, and a Subreddit Slideshow.

## The stack and the build tooling

The README lists what RedditJS is built with, and it records a particular moment in front-end development. The stack listed: Node, Backbone, Marionette, lodash, RequireJS, Handlebars and the Reddit API, hosted at Digital Ocean. The repository layout matches a RequireJS project rather than a bundled modern build. There is a Gruntfile.js at the root, a public directory, a server directory, a test directory, a package.json and package-lock.json, and a timestamp.json file. The devDependencies are grunt with grunt-contrib-jshint and grunt-contrib-requirejs, jshint, nodemon and uglify-js, which tells you the workflow: RequireJS modules assembled and minified through Grunt, with JSHint as the linter. The package.json declares the entry point as./server/server and the keywords are Marionette.js, Backbone.js, Require.js and Reddit, so the server is the main entry and the client is a set of AMD modules loaded through RequireJS.

## The Express server, session handling and Reddit authentication

The server side of package.json tells you more about how the app talks to Reddit. The Express 4 stack sits behind passport and passport-reddit, which is the Reddit OAuth strategy, so sign-in goes through Reddit's own account system rather than a local password store. Session handling uses express-session with cookie-session and cookie-parser, and connect-mongo with redis in the dependency list suggests a choice between Mongo-backed and Redis-backed session storage, or a cache layer in front of Reddit responses. There is also request for outbound HTTP, body-parser and raw-body for request bodies, method-override so the client can issue PUT and DELETE over POST, multiparty for uploads, compression for gzip responses, serve-static and serve-favicon for asset delivery, jade as the view template engine, bytes and qs for parsing, errorhandler for the error page, and async for control flow. The engines field is the detail worth noticing. It pins node at 0.11.14 and npm at 2.0.0, which dates this dependency set to 2015.

## The embed widgets, and how a third-party site uses them

The part of the project that outlives the app itself is the embeddable widgets. The README describes a post embed widget that you add to any website with a script tag, and the widget embeds itself onto your Wordpress post and detects if it has been posted to reddit. If it has not been posted, it shows a link to encourage the user to submit, and if it has been posted it loads a widget displaying that reddit post, giving the user somewhere to upvote and comment. The example with options shows the whole configuration surface in one tag.

```js
<script src='//redditjs.com/post.js' data-url='http://www.techodrom.com/etc/star-trek-edges-closer-reality-tractor-beam-moves-object-using-nothing-power-ultrasound/' data-height='500' data-width='500' data-post-finder='newest' data-theme='dark' data-show-submit='true'  </script>
```

The data attributes are documented as options: data-url for the URL to search in reddit, or a reddit post id, defaulting to the current URL of your site, data-width and data-height for the widget size, data-post-finder to choose between newest, mostUpvoted and mostComments when a URL has been submitted several times, data-theme for light or dark, and data-show-submit for whether to display a submit-to-reddit widget when nothing is found. A separate subreddit embed widget takes data-subreddit, data-domain, data-width, data-height, data-sort with hot, new, controversial, rising, top and gilded, data-theme, and a data-timeframe option for top and controversial sorts. There is also a Reddit Embed Wordpress Plugin for people who would rather configure it in WordPress.

## Where RedditJS is the wrong choice

Three limits, and the first is fatal for most uses. The dependency set pins node 0.11.14 and npm 2.0.0, and the libraries in the tree are of that era: uglify-js 2.x, jshint 2.6, grunt 0.4, request 2.36, redis 0.10, passport 0.2. The runtime those packages expect no longer exists on any current Node release, so running this today means an archaeology exercise with a Node 0.12 build or a container pinned to a decade-old image. The second limit is the dependency on Reddit's API and on reddit.com's own client-side conventions. The custom CSS feature works because subreddit styles are part of what Reddit serves, and the widget works because Reddit's own API exposes the post lookup. Both are couplings to a site this project does not control, and Reddit has changed its web client many times since. The third is that the described site, js4.red, appears to have been removed, so the code is a reference implementation rather than a running alternative. What survives is the design, which is genuinely instructive. Backbone for models and collections, Marionette for views and regions, RequireJS for module loading, Handlebars for templates, and a client-side cache that treats a subreddit as a memory-resident object rather than a page load.

## Conclusion

Adopt RedditJS only if you are studying how a Backbone and Marionette single page application is put together, or if you want the embed widgets for your own site. Skip it as a Reddit client in 2026, since the engines field pins 2015-era Node and npm and the live site it describes has been renamed. Before you base anything on it, check the engines field in package.json, which asks for node 0.11.14 and npm 2.0.0.

## FAQ

### What is RedditJS and what is it built with?

It is a reimplementation of the Reddit web interface written from the ground up with Backbone, using the Reddit API. The README lists Node, Backbone, Marionette, lodash, RequireJS, Handlebars and the Reddit API, hosted at Digital Ocean, with Grunt, JSHint and RequireJS handling the build.

### How does RedditJS handle subreddits it has already loaded?

Through its Data Cache. You only have to load up a subreddit once, after which it pulls the subreddit or single post from memory, which the README presents as a benefit for both Reddit's server and the reader since you only fetch once.

### How do I embed a RedditJS widget on my own site?

Add the post widget script tag to the page, optionally with data-url, data-width, data-height, data-post-finder, data-theme and data-show-submit attributes. There is a separate subreddit widget script with data-subreddit, data-domain, data-sort, data-timeframe and size and theme options, and a Reddit Embed Wordpress Plugin for WordPress sites.

### Can I still run RedditJS today?

Not without work. The package.json engines field pins node at 0.11.14 and npm at 2.0.0, and the dependencies are of that period, so a current Node release will not run it without porting. The README also notes that RedditJS is now known as js4.red and that the site it powered has been removed.

## Sources

- [BenjaminAdams/RedditJS on GitHub](https://github.com/BenjaminAdams/RedditJS)
- [Issues](https://github.com/BenjaminAdams/RedditJS/issues)
- [License: BSD-3-Clause](https://github.com/BenjaminAdams/RedditJS/blob/master/LICENSE)
- [README](https://github.com/BenjaminAdams/RedditJS/blob/master/README.md)

---

Hysen Labs editorial analysis, written from the project's own repository and release notes. Cite the canonical page: https://hysenlabs.com/projects/benjaminadams-redditjs
