This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension CGRect { | |
var center: CGPoint { | |
return .init(x: self.midX, y: self.midY) | |
} | |
} | |
struct PacMan: Shape { | |
var endAngle: Angle | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Okunabilirliği arttırmak amaçlı, düzenleme yaptım. | |
extension Path { | |
/// Begins a new subpath at the specified point. | |
func move(to p: CGPoint) | |
/// Appends a straight line segment from the current point to the | |
/// specified point. | |
func addLine(to p: CGPoint) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#if canImport(UIKit) | |
import UIKit | |
extension UIColor { | |
static var random: UIColor { | |
return UIColor( | |
red: .random(in: 0...1), | |
green: .random(in: 0...1), | |
blue: .random(in: 0...1) | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@UIApplicationMain | |
class AppDelegate: UIResponder, UIApplicationDelegate { | |
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { | |
// Override point for customization after application launch. | |
// .. | |
self.setupNetworkEnvironment() | |
return true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
enum Environment: String { | |
case production = "production" | |
case development = "development" | |
var url: String { | |
switch self { | |
case .development: | |
return "https://development.base.url/" | |
case .production: | |
return "https://production.base.url/" |
NewerOlder