Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/g33kdev/ra-appwrite
React Admin Data and Auth Providers for Appwrite
https://github.com/g33kdev/ra-appwrite
appwrite react-admin
Last synced: 3 months ago
JSON representation
React Admin Data and Auth Providers for Appwrite
- Host: GitHub
- URL: https://github.com/g33kdev/ra-appwrite
- Owner: g33kdev
- License: isc
- Created: 2021-11-23T20:53:15.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-08-11T16:00:24.000Z (over 1 year ago)
- Last Synced: 2024-10-03T19:15:08.736Z (4 months ago)
- Topics: appwrite, react-admin
- Language: TypeScript
- Homepage:
- Size: 37.1 KB
- Stars: 11
- Watchers: 2
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# ra-appwrite
[![Stable Release](https://img.shields.io/npm/v/ra-appwrite)](https://www.npmjs.com/package/ra-appwrite)
![License](https://img.shields.io/github/license/g33kdev/ra-appwrite.svg?style=flat-square)This package provides a Data Provider and Auth Provider to integrate [Appwrite](https://appwrite.io/) with [react-admin](https://marmelab.com/react-admin).
The Data Provider supports:
- Documents
The Auth Provider supports:
- Login
- Logout
- Permissions (Teams)## Installation
```sh
yarn add ra-appwrite
# or
npm install ra-appwrite
```## Usage
```jsx
import React from "react";
import { Appwrite } from "appwrite";
import { AppwriteDataProvider, AppwriteAuthProvider } from "ra-appwrite";
import {
Admin,
EditGuesser,
ListGuesser,
Resource,
ShowGuesser,
} from "react-admin";// Init your Web SDK
const appwrite = new Appwrite();appwrite
.setEndpoint("http://localhost/v1") // Your Appwrite Endpoint
.setProject("455x34dfkj"); // Your project ID// Create a mapping of resources to collection IDs
const resources = {
movies: "6160a2ca6b6fc",
};// Initialize the providers
const dataProvider = new AppwriteDataProvider(appwrite, resources);
const authProvider = new AppwriteAuthProvider(appwrite);const App = (): JSX.Element => (
);export default App;
```## Roadmap
- Add support for fetching teams
- Add support for fetching files