Structure of Naming conventions - jonasyr/gitray GitHub Wiki

   ██████╗ ██╗████████╗██████╗  █████╗ ██╗   ██╗
  ██╔════╝ ██║╚══██╔══╝██╔══██╗██╔══██╗╚██╗ ██╔╝
  ██║  ███╗██║   ██║   ██████╔╝███████║ ╚████╔╝ 
  ██║   ██║██║   ██║   ██╔══██╗██╔══██║  ╚██╔╝  
  ╚██████╔╝██║   ██║   ██║  ██║██║  ██║   ██║   
   ╚═════╝ ╚═╝   ╚═╝   ╚═╝  ╚═╝╚═╝  ╚═╝   ╚═╝   
    Official Wiki of the GitRay Repository!

Table of Contents

Description

This is a structure for Naming conventions.

Structure

  • PascalCase
    • for interfaces and React components
    • e.g. Commit, App
  • camelCase
    • for variables and functions
    • e.g. gitService, getCommits
  • kebab-case
    • for file names
    • e.g. error-handler.ts, package.json

Explanation

  • using PascalCase for components and interfaces makes their roles immediately clear and aligns with React and TypeScript community standards.
  • using camelCase for variables and functions keeps them visually distinct from types and components and matches the broader JavaScript ecosystem
  • employing kebab-case for filenames avoids import mismatches across different file systems and keeps URLs and paths clean

Altogether, this consistency reduces cognitive load, prevents errors, and lets tooling work out of the box.