spacetraders-v1 v0.1
spacetraders react client
I kicked off a new project to build a browser-based client for the SpaceTraders API. The idea is to create a React app that lets me interact with the game’s space trading mechanics through a web interface.
I started with Create React App and immediately set up a GitHub Actions workflow to deploy to Netlify. Getting CI/CD working early means I can iterate quickly and always have a live version running.
The core of the app is built around Redux for state management. I implemented a custom middleware to handle the async API calls, including a wrappedThunk helper to manage loading states and error handling consistently. There’s also some basic Jest test coverage for the middleware logic.
On the API side, I created TypeScript types for ships, loans, systems, locations, and the user account. The client can now create a new player, fetch available loans, request a loan, and display the user’s ships. I added a fun random name generator for new players.
For the UI, I built a simple status display showing the user’s credits and loans, plus a Player component that ties everything together. I also added a GitHub fork ribbon because why not.
More spacetraders-v1
My first implementation against the spacetraders api is an entirely browser-based UI and automation tool · source · play spacetraders-v1 · spacetraders api · posts