halljson / react-tetris

Frontend take home

Home Page:https://brandly.github.io/react-tetris/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

react-tetris

Usage

Step 1. Install dependencies

npm install

Step 2. Run the app on a local http server

npm run serve

Step 3. Watch for changes for real-time development

npm run watch

note: Most browsers will cache the exposed main.js file. If you make live changes to the code, you may need to clear your browser cache to see the changes. A simple way to do this is to open the developer tools and check the "Disable cache" checkbox in the "Network" tab.

Task

Your goal is to change the rules of the game so that instead of clearing lines, you clear connected components of size at least 10.

A connected component is a set of same colored blocks that are connected to each other by their 4 edges.

For example, the following board has 5 connected components 2 of which are of size at least 10 and should have been cleared if the new rules were in place.

Screenshot

Good luck!

About

Frontend take home

https://brandly.github.io/react-tetris/

License:MIT License


Languages

Language:TypeScript 94.1%Language:HTML 3.8%Language:Shell 2.1%