Convert readme code example to hooks (#280)
Convert readme code example to hooks (#280)

Co-authored-by: Sindre Sorhus <734af6fcbad65feee4fc3cad1b3f8a05746ffb9a@gmail.com>
Co-authored-by: Vadim Demedes <bccf26f43617db4eb99d9f959b18e54bd54d00ea@gmail.com>
vadimdemedes/ink,vadimdemedes/ink