Skip to content

tsitu/Redditor-or-Robot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

24fdf60 · Jan 13, 2019

History

55 Commits
Jun 28, 2017
Jan 13, 2019
Jul 5, 2017
Aug 23, 2017
Jan 13, 2019
Jul 4, 2017
Aug 23, 2017
Aug 21, 2017
Aug 22, 2017
Jan 13, 2019
Aug 22, 2017
Aug 23, 2017
Aug 23, 2017
Jan 6, 2019
Aug 23, 2017

Repository files navigation

Introduction

'Redditor or Robot?' is a game in which players put their bot-sniffing skills to the test. A random subreddit and its corresponding /r/SubredditSimulator user are selected from this list and it's up to you to figure out whether the displayed comment was written by a human... or a bot!

Gameplay

The current subreddit is reloaded when you guess incorrectly or after you've successfully identified 10 consecutive users. 3 mistakes and it's game over!

For the purposes of consistency and simplicity, a bot is defined as one that comments solely on /r/SubredditSimulator. If you encounter a bot masquerading as a human, please submit an issue so it can be added to this list.

Running Locally

  1. git clone https://github.com/tsitu/Redditor-or-Robot.git
  2. npm install
  3. Change APP_HOST in webpack.config.js to your local IPv4 address or leave it as 'localhost'
  4. Change 'build/code.min.js' to 'build/code.js' in index.html
  5. npm start

Development Environment

To use ESLint with VSCode

  1. npm install -g eslint eslint-config-airbnb eslint-plugin-import eslint-plugin-jsx-a11y eslint-plugin-react
  2. Open eslint-config-airbnb/rules/react.js and react-a11y.js in 'npm/node_modules' (via %appdata% on Windows) and make sure that 'ecmaFeatures' is wrapped in 'parserOptions' like so:
parserOptions: {
  ecmaFeatures: {
    jsx: true,
  },
},
  1. Install the ESLint extension and reload VSCode.
  2. Modify .eslintrc.json if necessary.
  3. Add the following to your local User\settings.json:
"eslint.validate": [
  "javascript",
  "javascriptreact",
  "html"
],

To use Flow with VSCode

  1. npm install -g flow-bin eslint-plugin-flowtype
  2. Install the Flow Language Support extension and reload VSCode.
  3. Modify src/.flowconfig if necessary and add /* @flow */ to the top of new files that require type checking.
  4. Add the following to your local User\settings.json:
"flow.pathToFlow": "{PATH_TO_FLOW_BIN}\\{FLOW_VERSION}\\flow.exe",
"javascript.validate.enable": false,

To build + minify

  1. npm install -g uglify-es uglify-js (if not already installed)
  2. npm run build

Technologies

License

FOSSA Status