Skip to content

Commit

Permalink
Fix digest export & update README
Browse files Browse the repository at this point in the history
  • Loading branch information
kaleabmelkie committed Apr 28, 2021
1 parent 1f72156 commit 44cace0
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2020 Kaleab S. Melkie
Copyright (c) 2020-2021 Kaleab S. Melkie

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,18 +31,18 @@ module.exports = {
// Could be just a strings,
`first@example.com`,
// Or an object, to pass an optional gravatar `query` parameter per email (see below).
{ email: `second@example.com`, query: `?size=128` }
]
{ email: `second@example.com`, query: `?size=128` },
],

// Optional.
// No query string is passed to gravatar by default.
// But you can add your gravatar query parameters here.
// See https://en.gravatar.com/site/implement/images/
// If this is set, it will be the default for `emails` (see above) with no `query` options.
query: `?size=64&m=dp`
}
}
]
query: `?size=64&m=dp`,
},
},
],
}
```

Expand Down Expand Up @@ -90,7 +90,7 @@ import { toUrl } from 'gatsby-source-gravatar'
function Profile({ email }) {
const url = useMemo(() => toUrl(email, 'size=128'), [email])

return <>...</>
return <img src={url} alt={`${email}'s gravatar`} />
}
```

Expand All @@ -109,4 +109,4 @@ Read up on [this article](https://medium.com/swlh/optimizing-gravatars-in-gatsby

Made with &hearts; in Addis Ababa.

[MIT License](LICENSE) &copy; 2020 [Kaleab S. Melkie](https://bit.ly/kaleab).
[MIT License](LICENSE) &copy; 2020-2021 [Kaleab S. Melkie](https://bit.ly/kaleab).
4 changes: 2 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
const digest = require('./lib/digest')
const md5 = require('md5')
const parseData = require('./lib/parse-data')
const parseNode = require('./lib/parse-node')
const toUrl = require('./lib/to-url')

module.exports = {
digest,
digest: md5,
parseData,
parseNode,
toUrl,
Expand Down

0 comments on commit 44cace0

Please sign in to comment.