Skip to content
This repository has been archived by the owner on Jan 5, 2024. It is now read-only.

[refactor] remove Constant.swift #27

Closed
3 tasks
ChoiysApple opened this issue Sep 6, 2023 · 0 comments · Fixed by #40
Closed
3 tasks

[refactor] remove Constant.swift #27

ChoiysApple opened this issue Sep 6, 2023 · 0 comments · Fixed by #40
Labels
♻️ Refactor Refactoring required
Milestone

Comments

@ChoiysApple
Copy link
Owner

Constant.swift

import Foundation

struct Colors {
    static let background = "BgColor"
    static let light_background = "LightBgColor"
    static let placeholder = "PlaceholderTextColor"
}

struct identifiers {
    static let discover_collection_cell = "DiscoverCollectionCell"
    static let discover_collection_header = "DiscoverCollectionHeader"
    
    static let chart_table_cell = "ChartTableCell"
    static let chart_table_header = "ChartTableHeader"
    
    static let credit_table_cell = "CreditTableCell"
    
    static let detail_trailer_collection_Cell = "DetailTrailerCollectionCell"
    static let detail_cast_collection_Cell = "DetailCastCollectionCell"
}


let genreCode = [
    28 : "Action",
    12 : "Adventure",
    16 : "Animation",
    35 : "Comedy",
    80 : "Crime",
    99 : "Documentary",
    18 : "Drama",
    10751 : "Family",
    14 : "Fantasy",
    36 : "History",
    27 : "Horror",
    10402 : "Music",
    9648 : "Mystery",
    10749 : "Romance",
    878 : "Science Fiction",
    10770 : "TV Movie",
    53 : "Thriller",
    10752 : "War",
    37 : "Western"
]
  • refactor color constant using UIColor extension
  • Make cell identifiers as static variable of class
  • Move genre code to Domain or Model part
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
♻️ Refactor Refactoring required
Projects
No open projects
Status: Deployed
1 participant