I've created a constant file on my application as constants.swift and I'm using struct to define constants as follows
struct moments {
struct parameter {
static let email = "email"
static let me = "me"
static let fields = "fields"
static let params = "id, name, first_name, last_name, picture.type(large), email"
}
struct title {
static let timeLineTitle = "Moments"
static let settingsTitle = "Settings"
static let menuTitle = "Menu"
static let openCamera = "Say Cheese!!! "
static let openGallery = "Pick from Moments "
static let addAudio = "Record Audio "
static let addNote = "Write Note "
}
struct notification {
static let notificationIdentifier = "NotificationIdentifier"
}
struct entity{
static let image = "Image"
static let note = "Note"
static let Audio = "Audio"
}
struct menu {
static let home = "Home"
static let settings = "Settings"
static let logout = "Logout"
}
struct cell {
static let cellIdentifier = "timeLineCell"
static let imageCell = "imageCell"
}
}
but I've found multiple other options like using class, singleton and enum I wanted to know which is the efficient way to use constants in my app...