us-state-map – a React component for a US map of states!

After releasing State Election Map, my first step was to publish a React component with just the map stuff in it. And after messing around for a while with npm and TypeScript and React, I got it working! The us-state-map component is now available on GitHub and npm, and State Election Map uses it. (it includes the map itself and the date slider)

As with whenever I mess around with React I’m pretty sure I’m doing some parts idiomatically “wrong”. (the build step in particular is pretty hacked-together) I like to work on stuff like this to learn how to do things, but it makes me wonder how much I actually learn if I’m just hacking things together and not doing it 100% the correct way. At least it does give me something to copy if I want to do something similar in the future, and I do feel a sense of accomplishment 🙂

One thought on “us-state-map – a React component for a US map of states!”

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s