Skip to content
Ian Philip Eglin edited this page Jun 16, 2024 · 9 revisions

Welcome to the MTELSYS Carrier Fair Website

Overview

This website is designed for the carrier fair organized by the electronics students at MTELSYS, NTNU, Trondheim. It provides information about the fair, participating companies, and allows students to interact with the event.

Technologies Used

The website is built using the following technologies:

  • NUXT 3 with Composition API: A powerful framework for building modern web applications with Vue.js.
  • Husky Pre-Commits with ESLint and Prettier: Ensures code quality and consistent formatting.
  • DigitalOcean: The project is hosted on DigitalOcean.com, providing scalability and reliability.

Additional Technology Suggestions

Here are some additional technologies you can consider adding to your tech stack:

  • Axios: A promise-based HTTP client for making API requests.
  • Tailwind CSS: A utility-first CSS framework for rapid UI development.
  • Jest and Vue Test Utils: Testing frameworks for unit and component testing.
  • Storybook: A tool for developing UI components in isolation.
  • Docker: Containerization platform for packaging and deploying applications.

Beginner Guides

To help newcomers to web development get started, we have prepared the following beginner guides:

  1. Git Guide:

  2. Testing Guide with Jest and Vue Test Utils:

  3. Introduction to HTML, CSS, and JavaScript:

  4. NUXT.js Beginner's Guide:

  5. Deployment Guide using DigitalOcean:

Development

  • Architecture
  • Routing
  • Data Fetching
  • Components

Getting Started!

Pre-requisites

  • Node.js (v16.11.0 or higher)
  • pnpm (v8.10.4 or higher)

Installation

Clone the repository using SSH:

git clone

Install dependencies:

# Navigate to the project root
cd ./etdagen

# Install dependencies
pnpm install

Setting up environments

Create a .env and .env.development file in the project root by copying the .env.example and file:

cp .env.example .env
cp .env.example .env.development

Replace xxxxx in the .env* file with the correct database value.

Add missing environment variables to the .env* file and Firebase admin SDK credentials, provided by the project manager.

Running the development server

Start the development server on http://localhost:3000

pnpm dev

Deployment

Automatic deployment to Digital Ocean App Platform when merging into main branch. Admin control for website must be managed by Head of IT. However, the App Platform allows for minimal overhead for team.

Check out the deployment documentation for more information.

Project Guidelines

Development

Issues

Issues should be created for all new features and bugs. The issue should be assigned to the person who will be working on it. The issue should be labeled with the appropriate label(s).

When deciding to work on a new issue, assign yourself to the issue and move it to the In progress column on the project board.

When opening a branch for the issue, click the Create a branch under Development on the GitHub issue page. Name the branch feature/issue_number-issue-title-in-kebab-case, and select Checkout locally. For example, if the issue number is 42 and the issue title is Add a new page, the branch should be named feature/42-add-a-new-page.

When the issue is completed, create a pull request and assign the pull request to the person who should review it. The issue should be moved to the In review column on the project board.

When the pull request is approved, merge it into the main branch and close the issue.

Branches

NB! All branches created working on issues should be branched off of dev.

The project uses the following branch naming conventions:

  • main - The main branch. This branch is protected and requires a pull request to be merged.
  • feature/issue_number-issue-title-in-kebab-case - A branch for a new feature.
  • fix/... - A branch for a bug fix.
  • refactor/... - A branch for refactoring.
  • chore/... - A branch for miscellaneous tasks.
  • More may be added in the future.

Commits

  • See Conventional Commits conventions for commit messages.

  • The projects has been configured with a husky pre-commit hook that runs npm run lintfix before every commit. This ensures that the code style is consistent.

Pull requests

  • Pull requests should be created for all new features and bugs. The pull request should be assigned to the person who should review it. The pull request should be labeled with the appropriate label(s).

Wiki Documentation

To maintain consistency and ease of understanding, we follow the following documentation standards:

  1. Use Markdown: Write documentation using Markdown syntax for easy readability and portability.
  2. Use headings: Structure your documentation using headings and subheadings.
  3. Provide examples: Include code snippets and examples to demonstrate the usage of different features.
  4. Add diagrams and images: Use visual aids to clarify complex concepts or workflows.
  5. Update regularly: Keep the documentation up to date as the project evolves.