benhurdavies / react-snake-game

A small game in react.js

Home Page:https://benhurdavies.github.io/react-snake-game/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

react-snake-game

Build Status contributions welcome HitCount license

A simple game build using react.js Try out the game

Installation

  • Install Node
  • Install the dependencies
yarn install

Getting Started

yarn start

Open your browser at http://localhost:3000/

Features

React and Redux

  • create-react-app - Facebook's create-react-app is used to get a production-ready React application quickly off the ground. It configures things like Webpack and Babel, so you don't have to.

  • Redux - We use Redux to manage complex application state. In the app, you'll find an example workflow to add items to a list.

  • konvajs - we use react-konva for HTML5 2d canvas for game area. It is a reactjs wrapper for konvajs

Styling

  • styled-components - we use styled-components to manage style outside game area.

  • material-ui - React components that implement Google's Material Design. View the docs here.

Tooling

  • Prettier - Prettier is wonderful magic that formats your JavaScript code for you. It is configured (using Husky) to format JavaScript code in a precommit hook. You may also choose to configure Prettier with your editor of choice.

  • Hot Module Replacement (HMR) - Hot Module Replacement updates the application on code change, without refreshing. Redux state is maintained.

  • Redux DevTools - Chrome extension - The app is configured to allow this Chrome extension to display dispatched actions and state diffs.

Testing

  • Jest - Facebook's Jest is configured out of the box with create-react-app. This comprehensive testing tool is built on top of Jasmine and will satisfy most of your unit testing needs.

  • Enzyme - Enzyme is pulled in to facilitate easier component testing.

Continuous Integration

Travis CI runs tests on each branch. Successful merges to master are auto deployed to the GitHub Page.

Development is in progress and welcomes contributions.

About

A small game in react.js

https://benhurdavies.github.io/react-snake-game/

License:MIT License


Languages

Language:JavaScript 94.5%Language:HTML 4.6%Language:Shell 0.9%