readme
This commit is contained in:
@@ -1,75 +1,67 @@
|
|||||||
# React + TypeScript + Vite
|
# AEGIS by GISE
|
||||||
|
|
||||||
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
|
Portail client B2B et coffre-fort numérique sécurisé pour la gestion d'infrastructures critiques. Conçu pour assurer la réassurance des dirigeants, le monitoring de l'infogérance et un support ITSM cloisonné.
|
||||||
|
|
||||||
Currently, two official plugins are available:
|
---
|
||||||
|
|
||||||
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react) uses [Oxc](https://oxc.rs)
|
## Stack Technique
|
||||||
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react-swc) uses [SWC](https://swc.rs/)
|
|
||||||
|
|
||||||
## React Compiler
|
* **Frontend :** ViteJS, React (TypeScript), Tailwind CSS (Design System "Corporate Trust").
|
||||||
|
* **Backend & Base de Données :** PocketBase (API REST & temps réel) sur infrastructure Bare-metal / Proxmox.
|
||||||
|
* **Sécurité & Auth :** Authentification fermée, multi-tenant par entreprise (`companies`), et MFA natif (TOTP / Google Authenticator via `otpauth`).
|
||||||
|
|
||||||
The React Compiler is not enabled on this template because of its impact on dev & build performances. To add it, see [this documentation](https://react.dev/learn/react-compiler/installation).
|
---
|
||||||
|
|
||||||
## Expanding the ESLint configuration
|
## Architecture des Collections (PocketBase)
|
||||||
|
|
||||||
If you are developing a production application, we recommend updating the configuration to enable type-aware lint rules:
|
Le backend repose sur un cloisonnement strict (Zero Trust / Multi-Tenant) via les API Rules PocketBase (`company = @request.auth.company.id`) :
|
||||||
|
|
||||||
```js
|
* `aegis_companies` : Données des entreprises clientes et niveaux VIP.
|
||||||
export default defineConfig([
|
* `aegis_aegis_users` : Comptes utilisateurs avec rôles et gestion du secret TOTP (`totp_secret`, `mfa_enabled`).
|
||||||
globalIgnores(['dist']),
|
* `aegis_infrastructure_nodes` : Équipements supervisés, statuts et métriques SLA.
|
||||||
{
|
* `aegis_tickets` : Centre de support ITSM (Incidents, Évolutions, Administratif).
|
||||||
files: ['**/*.{ts,tsx}'],
|
* `aegis_ticket_messages` : Fil de discussion chiffré et étanche relié aux tickets.
|
||||||
extends: [
|
* `aegis_documents_vault` : Stockage sécurisé des rapports d'audits et factures.
|
||||||
// Other configs...
|
* `aegis_managed_contracts` : Catalogue de lecture seule des services d'infogérance actifs.
|
||||||
|
|
||||||
// Remove tseslint.configs.recommended and replace with this
|
---
|
||||||
tseslint.configs.recommendedTypeChecked,
|
|
||||||
// Alternatively, use this for stricter rules
|
|
||||||
tseslint.configs.strictTypeChecked,
|
|
||||||
// Optionally, add this for stylistic rules
|
|
||||||
tseslint.configs.stylisticTypeChecked,
|
|
||||||
|
|
||||||
// Other configs...
|
## Installation & Lancement
|
||||||
],
|
|
||||||
languageOptions: {
|
### 1. Cloner et installer le front
|
||||||
parserOptions: {
|
```bash
|
||||||
project: ['./tsconfig.node.json', './tsconfig.app.json'],
|
git clone <url-du-repo>
|
||||||
tsconfigRootDir: import.meta.dirname,
|
cd aegis
|
||||||
},
|
npm install
|
||||||
// other options...
|
|
||||||
},
|
|
||||||
},
|
|
||||||
])
|
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
You can also install [eslint-plugin-react-x](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-x) and [eslint-plugin-react-dom](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-dom) for React-specific lint rules:
|
### 2. Configurer le client PocketBase
|
||||||
|
|
||||||
```js
|
Crée `src/config/pocketbase.ts` :
|
||||||
// eslint.config.js
|
|
||||||
import reactX from 'eslint-plugin-react-x'
|
|
||||||
import reactDom from 'eslint-plugin-react-dom'
|
|
||||||
|
|
||||||
export default defineConfig([
|
```typescript
|
||||||
globalIgnores(['dist']),
|
import PocketBase from 'pocketbase';
|
||||||
{
|
|
||||||
files: ['**/*.{ts,tsx}'],
|
export const pb = new PocketBase('https://pocket.gise.be');
|
||||||
extends: [
|
pb.autoCancellation(false);
|
||||||
// Other configs...
|
|
||||||
// Enable lint rules for React
|
```
|
||||||
reactX.configs['recommended-typescript'],
|
|
||||||
// Enable lint rules for React DOM
|
### 3. Lancer le backend PocketBase
|
||||||
reactDom.configs.recommended,
|
|
||||||
],
|
* Télécharge et lance l'exécutable PocketBase :
|
||||||
languageOptions: {
|
```bash
|
||||||
parserOptions: {
|
./pocketbase serve
|
||||||
project: ['./tsconfig.node.json', './tsconfig.app.json'],
|
|
||||||
tsconfigRootDir: import.meta.dirname,
|
```
|
||||||
},
|
|
||||||
// other options...
|
|
||||||
},
|
* Importe les schémas des collections depuis l'Admin UI (`https://pocket.gise.be/_/`) et applique les règles d'API multi-tenant.
|
||||||
},
|
|
||||||
])
|
### 4. Démarrer le frontend
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm run dev
|
||||||
|
|
||||||
```
|
```
|
||||||
Reference in New Issue
Block a user