How to prevent form spam

After publishing a quick little project to support contact forms on static websites, I was asked how spam should be handled.

Preventing common spam really isn’t all that hard, so I figured I’d write down a couple of techniques that should be useful for any contact form, comments section or really any form that accepts user input.

While there’s no silver bullet against spam bots, it’s easy enough to make it inconvenient enough for spammers to bother.

Building a reactive frontend

What do you do when you want a reactive rendering frontend in an environment with constraints that preclude the use of any modern framework?

You build your own, right? Right?

Don't ask that question

I’ve always been afraid of asking stupid questions. Silly, right? So I usually make sure I’ve done thorough research before asking a question when I get stuck. I also hate not understanding how things work. So I just try to figure them out. You should do the same!

Measuring software coupling

Coupling is about how objects in your application are connected: which objects depend on which, and how does that affect the entire system’s stability?

An application has tight coupling when a lot of components depend on each other. This should usually be avoided because a change in 1 place can cause issues in any of its dependencies.

So what does coupling tell you about your classes?