Skip to content

Instantly share code, notes, and snippets.

@jcreamer898
Last active February 2, 2018 01:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jcreamer898/08d6718b78be88b8c82c8f0ac1683e81 to your computer and use it in GitHub Desktop.
Save jcreamer898/08d6718b78be88b8c82c8f0ac1683e81 to your computer and use it in GitHub Desktop.
import * as React from "react";
import formatPrice from "../utils/formatPrice";
export interface IPriceProps {
num: number;
symbol: "$" | "€" | "£";
}
const Price: React.SFC<IPriceProps> = ({
num,
symbol
}: IPriceProps) => (
<div>
<h3>{formatPrice(num, symbol)}</h3>
</div>
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment