A comprehensive, modern website for Nyabihu Christian Academy, built with Next.js and Node.js.
Motto: "Generate a Child, Transform Generation"
Location: Nyabihu District, Rwanda
Type: Christian-based Private School
Levels: Nursery and Primary (P1βP6)
- Hero section with school branding
- About section with mission, vision, and values
- Academics overview
- Why choose NCA section
- Admissions information
- News & events preview
- Testimonials
- Call-to-action sections
- About Us - School history and philosophy
- Academics - Nursery and Primary programs, CBC curriculum
- Admissions - Application process and requirements
- Gallery - Photo albums and school memories
- News & Events - Announcements and upcoming events
- Contact Us - Contact form and location
- Student Portal - Secure login for students
- Staff Portal - Secure login for teachers and administrators
- Student management
- Teacher management
- Announcement management
- Event management
- Gallery management
- System settings
- Reports and analytics
- Framework: Next.js 14
- Styling: Tailwind CSS with custom design system
- State Management: React Context API
- Animations: Framer Motion
- Icons: Heroicons
- Form Handling: React Hook Form
- HTTP Client: Custom API client
- Runtime: Node.js
- Framework: Express.js
- Database: MongoDB with Mongoose ODM
- Authentication: JWT with bcrypt
- Validation: Express Validator
- File Upload: Multer
- Security: Helmet, CORS, Rate Limiting
- User - Admin, teachers, and parents
- Student - Student records and academic progress
- Announcement - School announcements and news
- Event - School events and activities
- Gallery - Photo galleries and albums
nca-website/
βββ backend/
β βββ models/ # MongoDB schemas
β βββ routes/ # API endpoints
β βββ middleware/ # Authentication and validation
β βββ utils/ # Utility functions
β βββ server.js # Main server file
β βββ package.json
βββ frontend/
β βββ app/ # Next.js app directory
β βββ components/ # Reusable components
β βββ lib/ # Utilities and API client
β βββ public/ # Static assets
β βββ styles/ # Global styles
β βββ package.json
β βββ README.md
βββ README.md
- Node.js (v16 or higher)
- MongoDB (local or cloud instance)
- npm or yarn
-
Navigate to the backend directory:
cd nca-website/backend -
Install dependencies:
npm install
-
Create
.envfile and configure:PORT=5000 MONGODB_URI=mongodb://localhost:27017/nca JWT_SECRET=your-super-secret-jwt-key JWT_EXPIRE=7d FRONTEND_URL=http://localhost:3000
-
Start the server:
npm run dev
-
Navigate to the frontend directory:
cd nca-website/frontend -
Install dependencies:
npm install
-
Create
.env.localfile:NEXT_PUBLIC_API_URL=http://localhost:5000/api
-
Start the development server:
npm run dev
-
Open your browser and visit
http://localhost:3000
POST /api/auth/register- User registrationPOST /api/auth/login- User loginGET /api/auth/me- Get current userPOST /api/auth/logout- User logoutPUT /api/auth/profile- Update profilePUT /api/auth/password- Change password
GET /api/students- Get all studentsGET /api/students/:id- Get student by IDPOST /api/students- Create new studentPUT /api/students/:id- Update studentDELETE /api/students/:id- Delete studentGET /api/students/parent/:parentId- Get students by parentPOST /api/students/:id/academic- Add academic recordPOST /api/students/:id/attendance- Add attendance record
GET /api/announcements- Get all announcementsGET /api/announcements/active- Get active announcementsPOST /api/announcements- Create announcementPUT /api/announcements/:id- Update announcementDELETE /api/announcements/:id- Delete announcementPUT /api/announcements/:id/publish- Publish announcement
GET /api/events- Get all eventsGET /api/events/upcoming- Get upcoming eventsPOST /api/events- Create eventPUT /api/events/:id- Update eventDELETE /api/events/:id- Delete eventPOST /api/events/:id/register- Register for event
GET /api/gallery- Get all galleriesGET /api/gallery/public- Get public galleriesPOST /api/gallery- Create galleryPUT /api/gallery/:id- Update galleryDELETE /api/gallery/:id- Delete galleryPOST /api/gallery/:id/images- Add images to gallery
- Primary Blue:
#0052cc - Gold:
#ffb800 - White:
#ffffff - Grays: Various shades for text and backgrounds
- Headings: Montserrat (Bold)
- Body: Poppins (Regular)
- Fallback: System fonts
- Mobile-first approach
- Responsive grid system
- Touch-friendly interactions
- Optimized for all screen sizes
- JWT authentication with secure tokens
- Password hashing with bcrypt
- Input validation and sanitization
- CORS configuration
- Rate limiting
- Helmet security headers
- Role-based access control
- Use semantic HTML
- Follow component-based architecture
- Maintain consistent naming conventions
- Write accessible code
- Use TypeScript for type safety (optional)
- Use feature branches
- Write descriptive commit messages
- Create pull requests for code review
- Follow conventional commit standards
- Unit tests for API endpoints
- Integration tests for critical flows
- E2E tests for user journeys
- Manual testing for UI/UX
- Set up a MongoDB instance (Atlas recommended)
- Configure environment variables
- Deploy to a cloud platform (Heroku, AWS, etc.)
- Set up SSL/HTTPS
- Configure domain and DNS
- Build the application:
npm run build - Deploy to Vercel, Netlify, or similar platform
- Configure environment variables
- Set up custom domain
- Enable SSL/HTTPS
- Fork the repository
- Create a feature branch
- Make your changes
- Write tests if applicable
- Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
For support and questions:
- Email: info@nca.rw
- Phone: +250 788 000 000
- Website: www.nca.rw
- Thanks to the NCA community for their support
- Open source libraries and frameworks used
- Educational standards and guidelines followed
Note: This is a comprehensive school management website designed to meet the needs of modern educational institutions while maintaining a strong Christian foundation.