0.4.2 • Published 5 months ago

react-ts-asteroids v0.4.2

Weekly downloads
-
License
ISC
Repository
github
Last release
5 months ago

React TypeScript Asteroids

A classic Asteroids game implementation as a React component, written in TypeScript.

Installation

npm install react-ts-asteroids

Quick Start

  1. Import the Asteroids component:
import { Asteroids } from 'react-ts-asteroids';
  1. Add it to your React application:
function App() {
  return (
    <div style={{ width: '100%', height: '100vh' }}>
      <Asteroids />
    </div>
  );
}

Note: The container element must have a defined width and height for the game to render properly.

Controls

Features

  • Classic Asteroids gameplay
  • Responsive design - adapts to container size
  • Score tracking with local storage for high scores
  • Particle effects for explosions and thrusters
  • Written in TypeScript with React

License

ISC

0.4.2

5 months ago

0.3.2

5 months ago

0.3.1

5 months ago

0.3.0

5 months ago

0.2.0

5 months ago

0.1.0

5 months ago