From what I've gathered the "sub" or "subject" field in the JWT token(https://tools.ietf.org/html/rfc7519#section-4.1) payload should be locally or globally unique. The documentation uses the username from the form data in the payload.
Is this a good practice? In a few examples I've found others using a unique id instead like 19898981.