No description, website, or topics provided.
JavaScript CSS Other
Permalink
Failed to load latest commit information.
.kage kage: Update manifests to use jinja2 for variables Sep 19, 2016
assets Modtools: mods can view reports & metadata Feb 22, 2017
hooks Add pre-commit, pre-push hooks May 26, 2016
src Fix momentum scrolling for subscription menu in iOS Feb 27, 2017
test Try to replace Reddit-hosted GIFs with MP4s during preview playback (#… Dec 20, 2016
.ackrc Add .ackrc Sep 8, 2016
.dockerignore Put Varnish in front of Node server via docker-compose. Sep 15, 2016
.drone.yml Move the drone messages from #frontend-platform to #mobile-web Oct 3, 2016
.editorconfig Add editorconfig file Jan 23, 2017
.eslintrc Revert "Revert "Add sentry to 2X"" Jan 31, 2017
.gitignore Add acceptance test suite for VCL rules. Sep 26, 2016
.gitmodules Remove art-gallery submodule Jun 15, 2016
.travis.yml Pass linter; add test command May 26, 2016
Dockerfile.dev Pull base images from Quay instead of Docker Hub. Sep 16, 2016
Dockerfile.staging Switch to branch and implement cross promotion experiment variants Nov 18, 2016
Dockerfile.varnish Mount default VCL instead of copying over. Oct 17, 2016
blueprints.config.js Inline @r/api-client Feb 14, 2017
default.vcl Fix VCL regexes to support parameters and/or subreddit searches. Nov 2, 2016
docker-compose.yml Mount default VCL instead of copying over. Oct 17, 2016
package.json inline @r/platform. Feb 27, 2017
readme.md Update readme with more comprehensive information. Jan 23, 2017
start.sh.example Move start.sh example from readme to start.sh.example Dec 14, 2016
tox.ini Add acceptance test suite for VCL rules. Sep 26, 2016

readme.md

Requirements

  • NodeJS v4.0+
  • NPM v3.10+
  • macOS or Linux (not tested on Windows)

Quick start

We use NPM scripts for all development related tasks.

git

The main git branch is 2X

We use rebasing in order to avoid merge commits.

Hooks

We have pre-commit/push hooks in the hooks directory to help enforce our linting rules and tests. Developers are highly encouraged to use them.

Configure your dev envirnoment

We use a shell script to run the app so we can define needed environment variables. By convention we call it start.sh. This file is already in our .gitignore.

cp start.sh.example start.sh chmod u+wx start.sh

Make sure to update the script with the appropriate secrets and other necessary values.

Install

npm install

Build/watch

watch - npm run watch build - npm run build

running the app

Instead of running the npm script that starts the server make sure to use your start.sh with the appropriate keys so you can log in.

./start.sh