🚨 Warning
Until we reach v1.0.0 the API still may change.
yarn add tonami
import { createTokens, styled, createGlobalStyle } from "tonami";
const theme = createTokens({
fontFamily: "Helvetica",
borderRadius: "3px",
});
const Global = createGlobalStyle({
html: {
fontFamily: theme.fontFamily,
},
});
const Banner = styled.div({
borderRadius: theme.borderRadius,
backgroundColor: ({ $color }) => $color,
});
const { Tokens } = theme;
function App() {
return (
<>
<Tokens />
<Global />
<Banner $color="lightgreen">Welcome!</Banner>
</>
);
}
Please file an issue for bugs or unexpected behavior.
Please file an issue to suggest new features. Vote on feature requests by adding a 👍.
- If on main, run
npm version 0.5.5
, otherwise runnpm version 0.5.5-beta.1
- Don't forget to run
yarn build
- If on main, run
git push && git push origin v0.5.5
, otherwise just push to your branch - If on main, run
npm publish
, otherwise runnpm publish --tag beta
MIT