nginx an elegant way to block a bunch of referrers at once

Source: nginx – Is there an elegant way to block a bunch of referrers at once? – Server Fault