π Best Practices
iOS Pull Request Checklistβ
This checklist provides a comprehensive guide for reviewing iOS pull requests, ensuring code quality and consistency in Swift projects.
Details
URL: π iOS Pull Request Checklist
Source: π GitHub Repository
Author: Aryaman Sharda
Tags:
Swift
, iOS
, Code Review
, Best Practices
Platforms Supported: iOS
Swift Version: 5.0 and above
Key Pointsβ
- Ensures adherence to coding standards and best practices.
- Focuses on code readability, performance, and security.
- Covers aspects like architecture, testing, and documentation.
Use Casesβ
- Standardizing code review processes across teams.
- Improving code quality and reducing technical debt.
- Facilitating consistent and thorough code reviews.
Alternative Approachesβ
- Using automated code review tools like SwiftLint.
- Implementing custom code review guidelines tailored to specific projects.
- Combining with peer review practices for comprehensive checks.
Checklist Categoriesβ
- Code Quality: Checks for code readability, maintainability, and adherence to standards.
- Architecture: Ensures proper design patterns and architectural principles.
- Testing: Verifies the presence and quality of unit and UI tests.
- Documentation: Ensures comprehensive documentation of code and changes.
- Performance: Checks for efficient and optimized code.
- Security: Ensures code is secure and free from vulnerabilities.
Related Resourcesβ
Referencesβ
iOS Asset Namesβ
This repository provides a comprehensive list of iOS Asset Names used across various iOS applications. It is an invaluable resource for developers looking to standardize or reference asset names efficiently, avoiding common pitfalls related to incorrect asset naming conventions.
Details
URL: π https://github.com/dkhamsing/ios-asset-names
Created: 2015-10-19
Last Updated: 2024-08-31
Authors/Curators: David Khamsing
Tags:
iOS
, Asset Management
, Best Practices
, Development Tools
, Resources
Overviewβ
The iOS Asset Names repository is a curated list that includes commonly used asset names in iOS development. The repository aims to help developers maintain consistency and adhere to best practices when naming assets in their projects. By providing a standardized reference, it minimizes errors that can occur due to misnamed assets, which is especially useful in large teams or open-source projects.
Categoriesβ
The repository organizes asset names into several key categories, making it easy to find the relevant names for specific types of assets:
- General Assets: Includes names for commonly used images, icons, and other assets that are widely applicable across various types of iOS apps.
- UI Components: This category lists names specific to user interface elements, such as buttons, navigation bars, and tab bar icons.
- App-Specific Assets: Contains names that are often used in specific types of applications, such as e-commerce, social media, or productivity apps.
Google Swift Style Guideβ
Details
URL: π Google Swift Style Guide
Published: Not specified
Last Updated: Not specified
Authors: Google Swift Team
Tags:
Swift
, Style Guide
, Coding Standards
Key Pointsβ
- Based on Appleβs Swift standard library style with input from Googleβs Swift projects.
- Emphasizes clear and consistent code formatting practices.
- Covers file structure, whitespace usage, string literals, and special escape sequences.
- Provides guidelines on naming conventions and the use of comments and imports.
Summary of Contentsβ
- Introduction: Overview of the Google Swift style guide.
- Source File Basics: Naming conventions and file encoding.
- Whitespace Characters: Usage of whitespace, excluding tab characters.
- Special Escape Sequences: Guidelines on using special escape sequences.
- Source File Structure: Recommendations on organizing code within source files.
- General Formatting: Rules for column limit, braces, semicolons, and line-wrapping.
- Documentation Comments: Standards for documenting code with examples.
- Programming Practices: Best practices for initializers, properties, and access levels.
Kodeco Swift Style Guideβ
Details
URL: π https://github.com/kodecocodes/swift-style-guide
Published: Not specified
Last Updated: Updated for Swift 5
Authors:
- Greg Heo
- Ray Fix
- Robb Critz
- Colin Eberhardt
- Samuel DeVore
- and others
Tags:
Swift
, iOS Development
, Style Guide
, Best Practices
Key Pointsβ
- Focuses on creating clear, consistent, and concise Swift code for print and web readability.
- Emphasizes using SwiftLint and adhering to Kodecoβs SwiftLint configuration.
- Discusses naming conventions, code organization, and best practices for classes, methods, and properties.
- Provides guidelines for generics, optionals, closures, and memory management.
- Highlights the importance of minimal imports, spacing, and protocol conformance.
Summary of Contentsβ
- Introduction: Overview of the purpose of the style guide.
- Correctness: Emphasizes writing code that compiles without warnings.
- Using SwiftLint: Encourages or requires the use of SwiftLint for consistent code style.
- Naming: Guidelines for naming conventions following Swift API Design Guidelines.
- Code Organization: Utilizes extensions for logical code organization.
- Protocol Conformance: Best practices for adding protocol conformance.
- Unused Code: Advocates for removing dead or unused code.
- Minimal Imports: Recommends importing only necessary modules.
- Spacing: Uses 2 spaces for indentation and avoids C-style comments.
Git Commit Message Guidelinesβ
This blog post by Tim Pope emphasizes the importance of writing clear and concise git commit messages. Pope argues that a well-crafted commit message helps maintain a project's history, makes it easier for others to understand changes, and ultimately contributes to the overall quality of the codebase. The article provides practical tips on how to write effective commit messages, including the use of imperative mood and keeping the first line short.
Details
URL: π https://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html
Platform: Git, Version Control Systems
Created: 2008-04-19
Authors/Developers: Tim Pope
Tags:
git
, commit-messages
, best-practices
, version-control
Key Pointsβ
- Imperative Mood Enforcement: Encourages the use of imperative mood in commit messages.
- Commit Message Structure: Provides a standardized structure for commit messages with a concise summary and optional detailed body.
- History Clarity: Ensures commit history remains clear and informative for future developers.
Use Casesβ
- Team Collaboration: Ensures all team members follow the same commit message conventions.
- Open Source Projects: Helps maintain a clear and understandable history for contributors and maintainers.
- Code Reviews: Facilitates better code reviews by providing clear context for each change.
Conventional Commitsβ
This repository is a curated collection of resources, tools, and best practices for implementing the Conventional Commits specification in your projects. Conventional Commits is a standardized format for commit messages that allows for more readable and consistent histories, which can be leveraged for automated versioning and change logs.
Details
URL: π Conventional Commits
Authors/Curators: Conventional Commits Team
Tags:
commit-messages
, best-practices
, version-control
, semantic-versioning
Categoriesβ
-
Specification: Detailed documentation on the Conventional Commits specification, including format rules, and examples.
- π Specification Overview: Introduction and full documentation of the Conventional Commits specification.
-
Tools: A curated list of tools and libraries that help enforce Conventional Commits in your projects.
- π Commitizen: A tool that prompts users to write commit messages in the Conventional Commits format.
- π Conventional Changelog: Automatically generate a changelog based on the Conventional Commits specification.
- π Husky: A tool to enforce commit message conventions with git hooks.
-
Best Practices: Articles and guides on how to implement Conventional Commits effectively in different types of projects.
- π Best Practices Guide: A guide on why and how to use Conventional Commits.
- π Real-World Examples: Examples of Conventional Commits in action.