Le dashboard JavaInHire est une Single Page Application (SPA) moderne qui sert d'interface utilisateur pour la plateforme d'emploi Java. Il intègre :
- Une authentification via AWS Cognito
- Une interface responsive avec animations CSS avancées
- Des micro-interactions utilisateur
- Une architecture modulaire
Composant | Technologie | Version | Usage |
---|---|---|---|
Core | HTML5 | - | Structure sémantique |
Styling | CSS3 | - | Animations, Flexbox, Grid |
Interactivité | JavaScript Vanilla | ES6+ | Gestion des événements |
Design System | Font Awesome | 6.4.0 | Icônes vectorielles |
Auth | AWS Cognito | - | Flux OAuth 2.0 |
Hébergement | Netlify | - | CDN & Déploiement continu |
:root {
--primary: #007bff; /* Couleur principale */
--secondary: #6c757d; /* Couleur secondaire */
--gradient: linear-gradient(90deg, #1a237e, #4b79a1); /* Dégradé header */
--transition: all 0.3s ease; /* Transition standard */
}
-
Animations Avancées :
- Keyframes pour les effets de flottement (
floating
) - Transitions CSS pour les micro-interactions
- Transformations 3D sur les cartes
- Keyframes pour les effets de flottement (
-
Approche Mobile-First :
- Media queries imbriquées
- Flexbox pour la disposition
- Unités relatives (rem/vw)
-
Performances :
- Pré-chargement des polices
- Optimisation des animations (will-change)
- Purge CSS automatique
// Configuration Cognito
const cognitoConfig = {
userPoolId: 'us-east-1_XXXXXXXXX',
clientId: '7sobukpqbbd431ucar9h1af6va',
oauth: {
domain: 'us-east-1xsabaucbj.auth.us-east-1.amazoncognito.com',
scope: ['email', 'openid', 'phone'],
redirectSignIn: 'https://collins-haya-portfolio.netlify.app/',
responseType: 'code'
}
};
-
Effet "Like" :
.beat { animation: beat 0.5s infinite; } @keyframes beat { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.2); } }
-
Navigation Mobile :
document.getElementById('hamburger').addEventListener('click', () => { document.getElementById('nav').classList.toggle('active'); });
Endpoint | Méthode | Usage |
---|---|---|
/api/offers |
GET | Récupération paginée |
/api/offers/{id}/favorite |
POST | Marquage favori |
fetch('https://javainhire-backend.onrender.com/api/offers')
.then(handleResponse)
.catch(handleError);
-
Build Process :
build: command: "echo 'No build needed'" publish: "/"
-
Headers Configuration :
/* Access-Control-Allow-Origin: * X-Frame-Options: DENY Content-Security-Policy: default-src 'self'
- Pré-chargement des assets critiques
- Compression Brotli/Gzip
- Cache Policy agressive
-
CSP Header :
Content-Security-Policy: default-src 'self'; script-src 'self' cdnjs.cloudflare.com; style-src 'self' 'unsafe-inline' cdnjs.cloudflare.com; img-src 'self' data:;
-
Protections :
- XSS filtering
- Clickjacking protection
- HSTS préchargé
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'GA_MEASUREMENT_ID');
</script>
- Score WCAG 2.1 AA
- ARIA landmarks
- Contrast ratio > 4.5:1
- Navigation au clavier
-
Optimisation des Images :
- WebP format
- Lazy loading
- srcset responsive
-
Performance :
// Pré-chargement des polices const font = new FontFace('CustomFont', 'url(...)'); font.load().then(() => document.fonts.add(font));
Structure prête pour :
- i18n (via Intl API)
- RTL support
- Localisation des dates
Device | Breakpoint | Layout |
---|---|---|
Mobile | < 768px | Single column |
Tablet | 768-992px | 2 columns |
Desktop | > 992px | 3 columns |
frontend/
├── assets/
│ ├── fonts/ # Polices custom
│ └── images/ # Images optimisées
├── css/
│ └── main.css # Styles minifiés
├── js/
│ ├── auth.js # Gestion Cognito
│ └── main.js # Logique principale
└── index.html # Entry point
-
End-to-End :
describe('Navigation', () => { it('should display login modal', () => { cy.get('#loginBtn').click(); cy.get('.modal').should('be.visible'); }); });
-
Lighthouse :
Performance: 98 Accessibility: 100 Best Practices: 100 SEO: 100
window.addEventListener('error', (e) => {
fetch('/api/log', {
method: 'POST',
body: JSON.stringify({
error: e.message,
stack: e.stack,
timestamp: new Date().toISOString()
})
});
});
-
Initialisation :
document.addEventListener('DOMContentLoaded', initApp);
-
Nettoyage :
window.addEventListener('beforeunload', cleanUp);
-
Q3 2025 :
- Intégration WebSocket pour notifications
- Progressive Web App
- Cache API
-
Q4 2025 :
- WebAssembly pour analyse CV
- Intégration Stripe
Pour toute question technique approfondie, n'hésitez pas à ouvrir une issue sur le dépôt GitHub.