-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrefine.config.js
58 lines (55 loc) · 1.7 KB
/
refine.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
/** @type {import('@refinedev/cli').RefineConfig} */
module.exports = {
group: "Data Provider",
swizzle: {
items: [
{
group: "Providers",
label: "PostgREST",
requiredPackages: ["@supabase/[email protected]"],
files: [
{
src: "./src/index.ts",
dest: "./providers/postgrest/index.ts",
},
{
src: "./src/dataProvider/index.ts",
dest: "./providers/postgrest/dataProvider/index.ts",
},
{
src: "./src/utils/index.ts",
dest: "./providers/postgrest/utils/index.ts",
},
{
src: "./src/utils/generateFilter.ts",
dest: "./providers/postgrest/utils/generateFilter.ts",
},
{
src: "./src/utils/handleError.ts",
dest: "./providers/postgrest/utils/handleError.ts",
},
{
src: "./src/utils/mapOperator.ts",
dest: "./providers/postgrest/utils/mapOperator.ts",
},
],
message: `
**\`Usage\`**
\`\`\`
// title: App.tsx
import { dataProvider, createClient } from "providers/postgrest";
const postgrestClient = createClient("POSTGREST_INSTANCE_URL");
const App = () => {
return (
<Refine
dataProvider={dataProvider(postgrestClient)}
/* ... */
/>
);
}
\`\`\`
`,
},
],
},
};