How to add “single pixel” edges to a Polygon2D

I’m looking to add “single pixel” edges to my Polygon2D objects, but I can’t figure out how. Here’s a simple example of what I’m hoping to achieve:

I’m still very new to shaders and it appears that making this is hard! Polygon2D polygons don’t have any default UV mapping, I’m not using any textures, and the pixel size of the outline would ideally be relative to the world and not to screen space.

How would I go about this?

Some sort of edge detection shader I would imagine. Not sure how accurate it would be though.