An open API service indexing awesome lists of open source software.

https://github.com/mogoatlhe/battleship

battleship game implemented in JS using TDD
https://github.com/mogoatlhe/battleship

css3 eslint html5 javascript jest webpack

Last synced: 3 months ago
JSON representation

battleship game implemented in JS using TDD

Awesome Lists containing this project

README

          

# Battleship

## Purpose

Implementing the Battleship [game]() in JavaScript following TDD principles using the Jest testing framework.

## Requirements

- [ ] Allow players to take turns during the game
- [ ] Make the computer capable of making random plays
- it should not make the same move twice
- it should be smart (it should try adjacent slots after placing a 'hit')
- [ ] End the game once one player's ships have all been sunk
- OPTIONAL:
- [ ] Create a two player option that lets users take turns by passing the device back and forth
- [ ] make sure the game is playable on a mobile device
- [ ] implement a "pass device" feature

## Technologies

- HTML5
- CSS3
- JavaScript

## Live Version

https://mogoatlhe.github.io/battleship - Not yet live

## Design

![](src/images/design.png)

## Lessons Learnt / Challenges Faced

- TDD
- Learnt how dragging and dropping HTML elements works