Files
JetsonMediaIOS/Jetson Media/been/Config.swift
2025-08-18 23:59:43 +08:00

28 lines
917 B
Swift
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import Foundation
// API
final class Config {
//
static let shared = Config()
// HOST
private let host = "https://jm.rbq.college"
//
private init() {}
// API
func apiURL(path: String) -> String {
// path
let formattedPath = path.starts(with: "/") ? path : "/\(path)"
return "\(host)\(formattedPath)"
}
// API
struct Path {
static let search = "search/" //
static let albumDetail = "album/" //
static let rankings = "rankings/" //
}
}