An open API service indexing awesome lists of open source software.

https://github.com/kadukeitor/files-fire

Files Fire is a proof of concept, that uses the new Material-UI version and Firebase in React.
https://github.com/kadukeitor/files-fire

firebase firebase-firestore firebase-storage material-design material-ui react react-router reactjs

Last synced: 11 months ago
JSON representation

Files Fire is a proof of concept, that uses the new Material-UI version and Firebase in React.

Awesome Lists containing this project

README

          

# Files Fire

Files Fire is a proof of concept,
that uses the new [Material-UI](https://material-ui.com) version and
[Firebase](https://firebase.google.com) in React.

![Alt text](.github/Files-Fire.png?raw=true "Files Fire")

## Getting Started

### 1. Clone the project
```
git clone https://github.com/kadukeitor/files-fire.git
```

### 2. Move to the project
```
cd files-fire
```

### 3. Install the dependencies
```
npm install
```

### 4. Create and complete the configuration file
```
cp .env.example .env
```

### 5. Run the project
```
npm start
```

## TODO

* Integrate a mime-type library
* Controlling the number of files that the user can upload.

## Firebase

### Firestore

#### Rules

```
service cloud.firestore {
match /databases/{database}/documents {
match /users/{userId}/{allDocuments=**} {
allow read, update, delete: if request.auth.uid == userId;
allow create: if request.auth.uid != null;
}
}
}
```

### Storage

#### Rules

```
service firebase.storage {
match /b/{bucket}/o {
match /users/{userId}/{allPaths=**} {
allow read: if request.auth.uid == userId;
allow write: if request.auth.uid == userId
&& request.resource.size < 10 * 1024 * 1024;
}
}
}
```

## Demo

Check the demo [here](https://kadukeitor.github.io/files-fire/)