By default, Xcode creates comments like this:
//
// AppDelegate.swift
// HeaderDemo
//
// Created by Cihat Gündüz on 09.05.19.
import Foundation | |
//: ## The Problem | |
// property example | |
let pollingInterval: TimeInterval = 5 | |
// method example | |
func animate(duration: TimeInterval = 20, animations: () -> Void) { |
import android.content.Context | |
import android.content.Context.MODE_PRIVATE | |
import android.content.SharedPreferences | |
import androidx.core.content.edit | |
object AppPreferences { | |
private var sharedPreferences: SharedPreferences? = null | |
// TODO step 1: call `AppPreferences.setup(applicationContext)` in your MainActivity's `onCreate` method | |
fun setup(context: Context) { |
// Copyright © 2020 Flinesoft. All rights reserved. | |
import Foundation | |
import SwiftUI | |
public struct SafeLocalizedStringKey : | |
ExpressibleByStringLiteral, | |
ExpressibleByStringInterpolation, | |
ExpressibleByExtendedGraphemeClusterLiteral, | |
ExpressibleByUnicodeScalarLiteral, |
#!/usr/local/bin/swift-sh | |
import AnyLint // @Flinesoft | |
try Lint.logSummaryAndExit(arguments: CommandLine.arguments) { | |
// MARK: - Variables | |
let swiftAppFiles: Regex = #"^(Shared|iOS|macOS)/App/Sources/.*\.swift$"# | |
// MARK: - Checks | |
// MARK: SafeLocalizedStringKey | |
let unsafeLocalizedStringKeyTypes: String = [ |
import android.icu.text.MeasureFormat | |
import android.icu.text.NumberFormat | |
import android.icu.util.MeasureUnit | |
import android.os.Build | |
import java.util.Locale | |
import kotlin.time.Duration | |
import kotlin.time.ExperimentalTime | |
import kotlin.time.days | |
import kotlin.time.hours | |
import kotlin.time.milliseconds |
# EditorConfig is awesome: https://editorconfig.org | |
root = true | |
[*] | |
indent_style = space | |
tab_width = 8 | |
indent_size = 4 | |
end_of_line = lf |