---
title: "Shared Singleton"
summary: "Definition for a singleton class"
completion-scope: Class Implementation
---

final class <#Singleton#> {

    static let sharedInstance = <#Singleton#>()

    init() {
        <#code#>
    }
    
}

---
title: "Shared Singleton"
summary: "Definition for a singleton class"
completion-scope: Class Implementation
---

class <#Singleton#> {

    static let sharedInstance = <#Singleton#>()

    init() {
        <#code#>
    }
    
}

--- 
+++ 
@@ -4,7 +4,7 @@
 completion-scope: Class Implementation
 ---
 
-class <#Singleton#> {
+final class <#Singleton#> {
 
     static let sharedInstance = <#Singleton#>()
 
Mark Singleton class as `final`

It's a singleton. Why are you subclassing it?