gitmyhub

spectrum

JavaScript ★ 11k updated 4y ago ▣ archived

Simple, powerful online communities.

The full source code for Spectrum, an online community platform combining real-time chat with threaded forums. Now part of GitHub, built with React, GraphQL, Node.js, and RethinkDB.

JavaScriptReactNode.jsGraphQLRethinkDBRedisFlowsetup: hardcomplexity 4/5

Spectrum was an online community platform designed to combine the best features of real-time chat apps and traditional forums. The goal was to help community owners grow and manage large online groups in a way that kept conversations organized and searchable rather than disappearing into an endless scroll of messages. The platform joined GitHub in November 2018.

The codebase is a monorepo containing the full product: a React frontend, a GraphQL API powered by the Apollo toolchain, a server-side rendering layer, and a set of background worker services. Data is stored in RethinkDB, background jobs run through Redis, and authentication is handled by PassportJS. Everything is written in JavaScript, with Flowtype for type safety.

Setting up the project locally requires installing RethinkDB and Redis before running the application. A script installs dependencies across all the individual service packages in the monorepo. After that, database migration and seeding scripts prepare the local data. Each server (API, web frontend, email worker, and others) runs as a separate process that you start individually with yarn commands.

The project is structured so different contributors can work on different pieces independently: the API server, the frontend app, the rendering server, and shared code each have their own directories. Code formatting is handled automatically by Prettier on commit. All new JavaScript files must include Flowtype type annotations as a CI requirement.

Spectrum is open source under the BSD 3-Clause license.

Where it fits