Skip to content

Commit

Permalink
fix: render emojis in user bio (#68)
Browse files Browse the repository at this point in the history
  • Loading branch information
diivi committed May 5, 2023
1 parent 4108432 commit d0158a5
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 1 deletion.
20 changes: 20 additions & 0 deletions npm-shrinkwrap.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
},
"dependencies": {
"@types/chrome": "^0.0.231",
"@types/node-emoji": "^1.8.2",
"node-emoji": "^1.11.0",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"react-icons": "^4.8.0"
Expand Down
3 changes: 2 additions & 1 deletion src/pages/profile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { DiJava } from "react-icons/di";
import OpenSaucedLogo from "../assets/opensauced-logo.svg";
import { getUserData, getUserPRData } from "../utils/fetchOpenSaucedApiData";
import { RouteContext } from "../App";
import { emojify } from "node-emoji";

const interestIcon = {
python: <SiPython />,
Expand Down Expand Up @@ -124,7 +125,7 @@ export const Profile = () => {
</div>}

{user?.bio && <span>
{user.bio}
{emojify(user.bio)}
</span>}

{user?.blog &&
Expand Down

0 comments on commit d0158a5

Please sign in to comment.