Getting started
Installation
Prerequisites
- Node.js version 18 or higher.
- A package manager: e.g. npm, pnpm, ...
sh
$ npm add @ogs-gmbh/guthrie-mui-bindingssh
$ pnpm add @ogs-gmbh/guthrie-mui-bindingssh
$ yarn add @ogs-gmbh/guthrie-mui-bindingssh
$ bun add @ogs-gmbh/guthrie-mui-bindingsUsage
Here's a simple example using getMuiComponentBindings. You can get a deeper understanding by looking at the reference.
example.tsx
tsx
import { Guthrie, withElements, withOperators, withFns } from "@ogs-gmbh/guthrie";
import { getMuiComponentBindings } from "@ogs-gmbh/guthrie-mui-bindings";
function MyPage() {
return (
<Guthrie
elements={withElements({
elements: getMuiComponentBindings({
mapNames: (value) => `mui-${value}`
})
})}
operators={withOperators({
options: {
universal: true
}
})}
fns={withFns({
options: {
native: true
}
})}
page={page}
/>
);
}