diff --git a/Example/AsyncReactorExample.xcodeproj/project.pbxproj b/Example/AsyncReactorExample.xcodeproj/project.pbxproj deleted file mode 100644 index 1cddb22..0000000 --- a/Example/AsyncReactorExample.xcodeproj/project.pbxproj +++ /dev/null @@ -1,382 +0,0 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 70; - objects = { - -/* Begin PBXBuildFile section */ - B4A9DDD22CF23EF2008CA694 /* Reactor in Frameworks */ = {isa = PBXBuildFile; productRef = B4A9DDD12CF23EF2008CA694 /* Reactor */; }; - B4ECB0C12A1250E000B0CAAE /* AsyncReactor in Frameworks */ = {isa = PBXBuildFile; productRef = B4ECB0C02A1250E000B0CAAE /* AsyncReactor */; }; - B4ECB0C82A12520700B0CAAE /* Logging in Frameworks */ = {isa = PBXBuildFile; productRef = B4ECB0C72A12520700B0CAAE /* Logging */; }; -/* End PBXBuildFile section */ - -/* Begin PBXFileReference section */ - B4ECB0AC2A1250AE00B0CAAE /* AsyncReactorExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = AsyncReactorExample.app; sourceTree = BUILT_PRODUCTS_DIR; }; - B4ECB0BE2A1250D700B0CAAE /* AsyncReactor */ = {isa = PBXFileReference; lastKnownFileType = wrapper; name = AsyncReactor; path = ..; sourceTree = ""; }; -/* End PBXFileReference section */ - -/* Begin PBXFileSystemSynchronizedRootGroup section */ - 82F565F82D74885200C72CA5 /* AsyncReactorExample */ = {isa = PBXFileSystemSynchronizedRootGroup; explicitFileTypes = {}; explicitFolders = (); path = AsyncReactorExample; sourceTree = ""; }; -/* End PBXFileSystemSynchronizedRootGroup section */ - -/* Begin PBXFrameworksBuildPhase section */ - B4ECB0A92A1250AE00B0CAAE /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - B4A9DDD22CF23EF2008CA694 /* Reactor in Frameworks */, - B4ECB0C82A12520700B0CAAE /* Logging in Frameworks */, - B4ECB0C12A1250E000B0CAAE /* AsyncReactor in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - B4ECB0A32A1250AE00B0CAAE = { - isa = PBXGroup; - children = ( - B4ECB0BE2A1250D700B0CAAE /* AsyncReactor */, - 82F565F82D74885200C72CA5 /* AsyncReactorExample */, - B4ECB0AD2A1250AE00B0CAAE /* Products */, - B4ECB0BF2A1250E000B0CAAE /* Frameworks */, - ); - sourceTree = ""; - }; - B4ECB0AD2A1250AE00B0CAAE /* Products */ = { - isa = PBXGroup; - children = ( - B4ECB0AC2A1250AE00B0CAAE /* AsyncReactorExample.app */, - ); - name = Products; - sourceTree = ""; - }; - B4ECB0BF2A1250E000B0CAAE /* Frameworks */ = { - isa = PBXGroup; - children = ( - ); - name = Frameworks; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXNativeTarget section */ - B4ECB0AB2A1250AE00B0CAAE /* AsyncReactorExample */ = { - isa = PBXNativeTarget; - buildConfigurationList = B4ECB0BB2A1250AF00B0CAAE /* Build configuration list for PBXNativeTarget "AsyncReactorExample" */; - buildPhases = ( - B4ECB0A82A1250AE00B0CAAE /* Sources */, - B4ECB0A92A1250AE00B0CAAE /* Frameworks */, - B4ECB0AA2A1250AE00B0CAAE /* Resources */, - ); - buildRules = ( - ); - dependencies = ( - ); - fileSystemSynchronizedGroups = ( - 82F565F82D74885200C72CA5 /* AsyncReactorExample */, - ); - name = AsyncReactorExample; - packageProductDependencies = ( - B4ECB0C02A1250E000B0CAAE /* AsyncReactor */, - B4ECB0C72A12520700B0CAAE /* Logging */, - B4A9DDD12CF23EF2008CA694 /* Reactor */, - ); - productName = AsyncReactorExample; - productReference = B4ECB0AC2A1250AE00B0CAAE /* AsyncReactorExample.app */; - productType = "com.apple.product-type.application"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - B4ECB0A42A1250AE00B0CAAE /* Project object */ = { - isa = PBXProject; - attributes = { - BuildIndependentTargetsInParallel = 1; - LastSwiftUpdateCheck = 1430; - LastUpgradeCheck = 1430; - TargetAttributes = { - B4ECB0AB2A1250AE00B0CAAE = { - CreatedOnToolsVersion = 14.3; - }; - }; - }; - buildConfigurationList = B4ECB0A72A1250AE00B0CAAE /* Build configuration list for PBXProject "AsyncReactorExample" */; - compatibilityVersion = "Xcode 14.0"; - developmentRegion = en; - hasScannedForEncodings = 0; - knownRegions = ( - en, - Base, - ); - mainGroup = B4ECB0A32A1250AE00B0CAAE; - packageReferences = ( - B4ECB0C62A12520700B0CAAE /* XCRemoteSwiftPackageReference "swift-log" */, - ); - productRefGroup = B4ECB0AD2A1250AE00B0CAAE /* Products */; - projectDirPath = ""; - projectRoot = ""; - targets = ( - B4ECB0AB2A1250AE00B0CAAE /* AsyncReactorExample */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXResourcesBuildPhase section */ - B4ECB0AA2A1250AE00B0CAAE /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXResourcesBuildPhase section */ - -/* Begin PBXSourcesBuildPhase section */ - B4ECB0A82A1250AE00B0CAAE /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin XCBuildConfiguration section */ - B4ECB0B92A1250AF00B0CAAE /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - ENABLE_TESTABILITY = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_DYNAMIC_NO_PIC = NO; - GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PREPROCESSOR_DEFINITIONS = ( - "DEBUG=1", - "$(inherited)", - ); - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; - MTL_FAST_MATH = YES; - ONLY_ACTIVE_ARCH = YES; - SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; - SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - }; - name = Debug; - }; - B4ECB0BA2A1250AF00B0CAAE /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - MTL_ENABLE_DEBUG_INFO = NO; - MTL_FAST_MATH = YES; - SWIFT_COMPILATION_MODE = wholemodule; - SWIFT_OPTIMIZATION_LEVEL = "-O"; - }; - name = Release; - }; - B4ECB0BC2A1250AF00B0CAAE /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = AsyncReactorExample/AsyncReactorExample.entitlements; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_ASSET_PATHS = "\"AsyncReactorExample/Preview Content\""; - ENABLE_PREVIEWS = YES; - GENERATE_INFOPLIST_FILE = YES; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - IPHONEOS_DEPLOYMENT_TARGET = 16.4; - LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; - "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 13.3; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = io.diamir.AsyncReactorExample; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = auto; - SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_STRICT_CONCURRENCY = complete; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Debug; - }; - B4ECB0BD2A1250AF00B0CAAE /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = AsyncReactorExample/AsyncReactorExample.entitlements; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_ASSET_PATHS = "\"AsyncReactorExample/Preview Content\""; - ENABLE_PREVIEWS = YES; - GENERATE_INFOPLIST_FILE = YES; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSceneManifest_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphoneos*]" = YES; - "INFOPLIST_KEY_UILaunchScreen_Generation[sdk=iphonesimulator*]" = YES; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphoneos*]" = UIStatusBarStyleDefault; - "INFOPLIST_KEY_UIStatusBarStyle[sdk=iphonesimulator*]" = UIStatusBarStyleDefault; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; - IPHONEOS_DEPLOYMENT_TARGET = 16.4; - LD_RUNPATH_SEARCH_PATHS = "@executable_path/Frameworks"; - "LD_RUNPATH_SEARCH_PATHS[sdk=macosx*]" = "@executable_path/../Frameworks"; - MACOSX_DEPLOYMENT_TARGET = 13.3; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = io.diamir.AsyncReactorExample; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = auto; - SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx"; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_STRICT_CONCURRENCY = complete; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Release; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - B4ECB0A72A1250AE00B0CAAE /* Build configuration list for PBXProject "AsyncReactorExample" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - B4ECB0B92A1250AF00B0CAAE /* Debug */, - B4ECB0BA2A1250AF00B0CAAE /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - B4ECB0BB2A1250AF00B0CAAE /* Build configuration list for PBXNativeTarget "AsyncReactorExample" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - B4ECB0BC2A1250AF00B0CAAE /* Debug */, - B4ECB0BD2A1250AF00B0CAAE /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; -/* End XCConfigurationList section */ - -/* Begin XCRemoteSwiftPackageReference section */ - B4ECB0C62A12520700B0CAAE /* XCRemoteSwiftPackageReference "swift-log" */ = { - isa = XCRemoteSwiftPackageReference; - repositoryURL = "https://github.com/apple/swift-log"; - requirement = { - kind = upToNextMajorVersion; - minimumVersion = 1.0.0; - }; - }; -/* End XCRemoteSwiftPackageReference section */ - -/* Begin XCSwiftPackageProductDependency section */ - B4A9DDD12CF23EF2008CA694 /* Reactor */ = { - isa = XCSwiftPackageProductDependency; - productName = Reactor; - }; - B4ECB0C02A1250E000B0CAAE /* AsyncReactor */ = { - isa = XCSwiftPackageProductDependency; - productName = AsyncReactor; - }; - B4ECB0C72A12520700B0CAAE /* Logging */ = { - isa = XCSwiftPackageProductDependency; - package = B4ECB0C62A12520700B0CAAE /* XCRemoteSwiftPackageReference "swift-log" */; - productName = Logging; - }; -/* End XCSwiftPackageProductDependency section */ - }; - rootObject = B4ECB0A42A1250AE00B0CAAE /* Project object */; -} diff --git a/Example/AsyncReactorExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/Example/AsyncReactorExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata deleted file mode 100644 index 919434a..0000000 --- a/Example/AsyncReactorExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata +++ /dev/null @@ -1,7 +0,0 @@ - - - - - diff --git a/Example/AsyncReactorExample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/Example/AsyncReactorExample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist deleted file mode 100644 index 18d9810..0000000 --- a/Example/AsyncReactorExample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +++ /dev/null @@ -1,8 +0,0 @@ - - - - - IDEDidComputeMac32BitWarning - - - diff --git a/Example/AsyncReactorExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/Example/AsyncReactorExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved deleted file mode 100644 index ab8ab37..0000000 --- a/Example/AsyncReactorExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ /dev/null @@ -1,14 +0,0 @@ -{ - "pins" : [ - { - "identity" : "swift-log", - "kind" : "remoteSourceControl", - "location" : "https://github.com/apple/swift-log", - "state" : { - "revision" : "32e8d724467f8fe623624570367e3d50c5638e46", - "version" : "1.5.2" - } - } - ], - "version" : 2 -} diff --git a/Example/AsyncReactorExample/Assets.xcassets/AccentColor.colorset/Contents.json b/Example/AsyncReactorExample/Assets.xcassets/AccentColor.colorset/Contents.json deleted file mode 100644 index eb87897..0000000 --- a/Example/AsyncReactorExample/Assets.xcassets/AccentColor.colorset/Contents.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "colors" : [ - { - "idiom" : "universal" - } - ], - "info" : { - "author" : "xcode", - "version" : 1 - } -} diff --git a/Example/AsyncReactorExample/Assets.xcassets/AppIcon.appiconset/Contents.json b/Example/AsyncReactorExample/Assets.xcassets/AppIcon.appiconset/Contents.json deleted file mode 100644 index 532cd72..0000000 --- a/Example/AsyncReactorExample/Assets.xcassets/AppIcon.appiconset/Contents.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "images" : [ - { - "idiom" : "universal", - "platform" : "ios", - "size" : "1024x1024" - }, - { - "idiom" : "mac", - "scale" : "1x", - "size" : "16x16" - }, - { - "idiom" : "mac", - "scale" : "2x", - "size" : "16x16" - }, - { - "idiom" : "mac", - "scale" : "1x", - "size" : "32x32" - }, - { - "idiom" : "mac", - "scale" : "2x", - "size" : "32x32" - }, - { - "idiom" : "mac", - "scale" : "1x", - "size" : "128x128" - }, - { - "idiom" : "mac", - "scale" : "2x", - "size" : "128x128" - }, - { - "idiom" : "mac", - "scale" : "1x", - "size" : "256x256" - }, - { - "idiom" : "mac", - "scale" : "2x", - "size" : "256x256" - }, - { - "idiom" : "mac", - "scale" : "1x", - "size" : "512x512" - }, - { - "idiom" : "mac", - "scale" : "2x", - "size" : "512x512" - } - ], - "info" : { - "author" : "xcode", - "version" : 1 - } -} diff --git a/Example/AsyncReactorExample/Assets.xcassets/Contents.json b/Example/AsyncReactorExample/Assets.xcassets/Contents.json deleted file mode 100644 index 73c0059..0000000 --- a/Example/AsyncReactorExample/Assets.xcassets/Contents.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "info" : { - "author" : "xcode", - "version" : 1 - } -} diff --git a/Example/AsyncReactorExample/AsyncReactorExample.entitlements b/Example/AsyncReactorExample/AsyncReactorExample.entitlements deleted file mode 100644 index f2ef3ae..0000000 --- a/Example/AsyncReactorExample/AsyncReactorExample.entitlements +++ /dev/null @@ -1,10 +0,0 @@ - - - - - com.apple.security.app-sandbox - - com.apple.security.files.user-selected.read-only - - - diff --git a/Example/AsyncReactorExample/AsyncReactorExampleApp.swift b/Example/AsyncReactorExample/AsyncReactorExampleApp.swift deleted file mode 100644 index 02ebb54..0000000 --- a/Example/AsyncReactorExample/AsyncReactorExampleApp.swift +++ /dev/null @@ -1,27 +0,0 @@ -// -// AsyncReactorExampleApp.swift -// AsyncReactorExample -// -// Created by Dominik Arnhof on 15.05.23. -// - -import SwiftUI -import Logging - -@main -struct AsyncReactorExampleApp: App { - - init() { - LoggingSystem.bootstrap { label in - var standardOutputLogHandler = StreamLogHandler.standardOutput(label: label) - standardOutputLogHandler.logLevel = .debug - return standardOutputLogHandler - } - } - - var body: some Scene { - WindowGroup { - ContentView() - } - } -} diff --git a/Example/AsyncReactorExample/ContentView.swift b/Example/AsyncReactorExample/ContentView.swift deleted file mode 100644 index de85640..0000000 --- a/Example/AsyncReactorExample/ContentView.swift +++ /dev/null @@ -1,18 +0,0 @@ -import SwiftUI -import AsyncReactor - -struct ContentView: View { - var body: some View { - ReactorView(RepositorySearchReactor()) { - RepositorySearchView() - } - } -} - -struct ContentView_Previews: PreviewProvider { - static var previews: some View { - NavigationStack { - ContentView() - } - } -} diff --git a/Example/AsyncReactorExample/Features/Repository/Detail/RepositoryDescriptionSheet.swift b/Example/AsyncReactorExample/Features/Repository/Detail/RepositoryDescriptionSheet.swift deleted file mode 100644 index 463c8a9..0000000 --- a/Example/AsyncReactorExample/Features/Repository/Detail/RepositoryDescriptionSheet.swift +++ /dev/null @@ -1,23 +0,0 @@ -// -// RepositoryDescriptionSheet.swift -// AsyncReactorExample -// -// Created by Ahmet Bozkan on 23.05.23. -// - -import SwiftUI - -struct RepositoryDescriptionSheet: View { - var description: String - - var body: some View { - Text(description) - .padding() - } -} - -struct RepositoryDescriptionSheet_Previews: PreviewProvider { - static var previews: some View { - RepositoryDescriptionSheet(description: "Description") - } -} diff --git a/Example/AsyncReactorExample/Features/Repository/Detail/RepositoryDetailReactor.swift b/Example/AsyncReactorExample/Features/Repository/Detail/RepositoryDetailReactor.swift deleted file mode 100644 index bff699d..0000000 --- a/Example/AsyncReactorExample/Features/Repository/Detail/RepositoryDetailReactor.swift +++ /dev/null @@ -1,54 +0,0 @@ -// -// RepositoryDetailReactor.swift -// AsyncReactorExample -// -// Created by Ahmet Bozkan on 22.05.23. -// - -import Foundation -import AsyncReactor -import Logging - -private let logger = Logger(label: "RepositoryDetailReactor") - -class RepositoryDetailReactor: AsyncReactor { - - enum Action { - case setSheetPresented(Bool) - case longRunningAction - } - - struct State { - var sheetPresented = false - var longRunningActionRunning = false - } - - @Published - private(set) var state: State - - @MainActor - init(state: State = State()) { - self.state = state - } - - - func action(_ action: Action) async { - switch(action) { - case .setSheetPresented(let isPresented): - state.sheetPresented = isPresented - case .longRunningAction: - do { - state.longRunningActionRunning = true - - try await Task.sleep(for: .seconds(5)) - - state.longRunningActionRunning = false - - logger.debug("long running action success") - } catch { - logger.error("long running action error: \(error)") - } - } - } - -} diff --git a/Example/AsyncReactorExample/Features/Repository/Detail/RepositoryDetailView.swift b/Example/AsyncReactorExample/Features/Repository/Detail/RepositoryDetailView.swift deleted file mode 100644 index 38c08c8..0000000 --- a/Example/AsyncReactorExample/Features/Repository/Detail/RepositoryDetailView.swift +++ /dev/null @@ -1,87 +0,0 @@ -// -// RepositoryDetailView.swift -// AsyncReactorExample -// -// Created by Ahmet Bozkan on 22.05.23. -// - -import SwiftUI -import AsyncReactor - -struct RepositoryDetailView: View { - @EnvironmentObject - private var reactor: RepositoryDetailReactor - - var repository: Repository - - @ActionBinding(RepositoryDetailReactor.self, keyPath: \.sheetPresented, action: RepositoryDetailReactor.Action.setSheetPresented) - private var sheetPresented: Bool - - var body: some View { - ScrollView { - AsyncImage(url: URL(string: repository.owner.avatarUrl)) { image in - image - .resizable() - .clipShape(Circle()) - .overlay { - Circle().stroke(.white, lineWidth: 4) - } - .shadow(radius: 7) - .scaledToFit() - .frame(height: 200) - } placeholder: { - ProgressView() - } - - VStack(alignment: .leading) { - HStack { - Text(repository.name) - .font(.title2) - - Spacer() - - Label("Visibility", systemImage: repository.isVisible ? "lock.open" : "lock") - .labelStyle(.iconOnly) - .foregroundColor(repository.isVisible ? Color.green : Color.red) - } - - Divider() - - Button("Show Description") { - reactor.send(.setSheetPresented(true)) - } - .disabled(reactor.longRunningActionRunning) - - Spacer() - - Button("Long running action") { - reactor.send(.longRunningAction, id: .init(id: "longRunning", mode: [.lifecycle, .inFlight])) - } - - if reactor.longRunningActionRunning { - ProgressView() - } - } - } - .padding(.horizontal) - .toolbar { - Link(destination: URL(string: repository.htmlUrl)!) { - Image(systemName: "square.and.arrow.up") - } - } - .sheet(isPresented: $sheetPresented) { - NavigationStack { - RepositoryDescriptionSheet(description: repository.description ?? "") - } - } - } -} - -struct RepositoryDetailView_Previews: PreviewProvider { - static var previews: some View { - NavigationStack { - RepositoryDetailView(repository: Repository(id: 0, name: "Test Repo", fullName: "github/Test Repo", description: "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse ultricies nisi elit, non imperdiet nibh euismod in. Sed sit amet tincidunt arcu, nec ornare nisl. Pellentesque sollicitudin quam quis elit tempus, et interdum lorem tristique. Nunc rhoncus ornare efficitur. Ut tellus libero, pretium sit amet dolor a, maximus scelerisque sem. Phasellus posuere aliquam purus. Mauris justo tellus, molestie ut eros at, lobortis luctus nulla. Nullam libero leo, sagittis ac orci nec, viverra faucibus lacus. Phasellus faucibus ipsum nec velit mattis tincidunt. Phasellus nulla mauris, lobortis ac quam non, consectetur viverra odio. Praesent sed venenatis nulla. Praesent non maximus sem, quis ultricies ligula. Aliquam eleifend non velit eget venenatis. Vivamus aliquet, nisl vestibulum cursus aliquet, neque justo feugiat magna, eu suscipit turpis mi id orci.", htmlUrl: "google.com",watchersCount: 1, forks: 1, visibility: "public", owner: Repository.Owner(avatarUrl: "https://avatars.githubusercontent.com/u/60294?v=4"))) - } - .environmentObject(RepositoryDetailReactor()) - } -} diff --git a/Example/AsyncReactorExample/Features/Repository/Search/RepositoryItem.swift b/Example/AsyncReactorExample/Features/Repository/Search/RepositoryItem.swift deleted file mode 100644 index b249662..0000000 --- a/Example/AsyncReactorExample/Features/Repository/Search/RepositoryItem.swift +++ /dev/null @@ -1,38 +0,0 @@ -// -// RepositoryItem.swift -// AsyncReactorExample -// -// Created by Ahmet Bozkan on 22.05.23. -// - -import SwiftUI -import AsyncReactor - -struct RepositoryItem: View { - var repository: Repository - - var body: some View { - NavigationLink(value: repository) { - HStack { - AsyncImage(url: URL(string: repository.owner.avatarUrl)) { image in - image - .resizable() - .frame(width: 50, height: 50) - .scaledToFit() - .cornerRadius(8) - } placeholder: { - ProgressView() - } - - Text(repository.fullName) - .font(.body) - } - } - } -} - -struct RepositoryItem_Previews: PreviewProvider { - static var previews: some View { - RepositoryItem(repository: Repository(id: 0, name: "Test Repo", fullName: "github/Test Repo", description: "", htmlUrl: "google.com", watchersCount: 1, forks: 1, visibility: "public", owner: Repository.Owner(avatarUrl: "https://avatars.githubusercontent.com/u/60294?v=4"))) - } -} diff --git a/Example/AsyncReactorExample/Features/Repository/Search/RepositoryList.swift b/Example/AsyncReactorExample/Features/Repository/Search/RepositoryList.swift deleted file mode 100644 index 485a9c0..0000000 --- a/Example/AsyncReactorExample/Features/Repository/Search/RepositoryList.swift +++ /dev/null @@ -1,30 +0,0 @@ -// -// RepositoryList.swift -// AsyncReactorExample -// -// Created by Ahmet Bozkan on 22.05.23. -// - -import SwiftUI - -struct RepositoryList: View { - var repositories: [Repository] - - var body: some View { - ForEach(repositories) { repository in - RepositoryItem(repository: repository) - .padding(4) - } - } -} - -struct RepositoryList_Previews: PreviewProvider { - static var previews: some View { - RepositoryList(repositories: [ - Repository(id: 0, name: "Test Repo", fullName: "github/Test Repo", description: "",htmlUrl: "google.com",watchersCount: 1, forks: 1, visibility: "public", owner: Repository.Owner(avatarUrl: "https://avatars.githubusercontent.com/u/60294?v=4")), - Repository(id: 0, name: "Test Repo", fullName: "github/Test Repo", description: "",htmlUrl: "google.com",watchersCount: 1, forks: 1, visibility: "public", owner: Repository.Owner(avatarUrl: "https://avatars.githubusercontent.com/u/60294?v=4")), - Repository(id: 0, name: "Test Repo", fullName: "github/Test Repo", description: "",htmlUrl: "google.com",watchersCount: 1, forks: 1, visibility: "public", owner: Repository.Owner(avatarUrl: "https://avatars.githubusercontent.com/u/60294?v=4")), - Repository(id: 0, name: "Test Repo", fullName: "github/Test Repo", description: "", htmlUrl: "google.com",watchersCount: 1, forks: 1,visibility: "public", owner: Repository.Owner(avatarUrl: "https://avatars.githubusercontent.com/u/60294?v=4")) - ]) - } -} diff --git a/Example/AsyncReactorExample/Features/Repository/Search/RepositorySearchReactor.swift b/Example/AsyncReactorExample/Features/Repository/Search/RepositorySearchReactor.swift deleted file mode 100644 index 7e7bb4f..0000000 --- a/Example/AsyncReactorExample/Features/Repository/Search/RepositorySearchReactor.swift +++ /dev/null @@ -1,119 +0,0 @@ -// -// TestReactor.swift -// Rudi -// -// Created by Dominik Arnhof on 14.04.23. -// - -import Foundation -import AsyncReactor -import UIKit -import Logging - -private let logger = Logger(label: "RepositorySearchReactor") - -enum SortOptions: String, CaseIterable, Identifiable { - var id: Self { return self } - - case watchers - case forks - - var displayName: String { - switch self { - case .watchers: - return "Watchers Count" - case .forks: - return "Forks" - } - } -} - -class RepositorySearchReactor: AsyncReactor { - enum Action { - case onHidePrivateToggle - case enterQuery(String) - case load - case onSortOptionSelected(SortOptions) - } - - enum SyncAction { - case toggleHidePrivate - } - - struct State { - var hidePrivate = false - var query = "" - var repositories: [Repository] = [] - var isLoading = false - var sortBy: SortOptions = .watchers - } - - @Published - private(set) var state: State - - init(state: State = State()) { - self.state = state - - let sortBy = UserDefaults.standard.string(forKey: "sortBy") ?? SortOptions.watchers.rawValue - self.handleSortOption(sortBy) - - lifecycleTask { - for await _ in NotificationCenter.default.publisher(for: UIApplication.didBecomeActiveNotification).values { - await self.action(.load) - } - - logger.debug("lifecycleTask cancelled") - } - } - - func action(_ action: Action) async { - switch action { - case .onHidePrivateToggle: - state.hidePrivate.toggle() - - case .enterQuery(let query): - state.query = query - - try? await Task.sleep(for: .seconds(1)) - - guard !Task.isCancelled else { return } - - await self.action(.load) - case .load: - state.isLoading = true - - do { - let currentQuery = state.query.isEmpty ? "iOS" : state.query - let (data, _) = try await URLSession.shared.data(from: URL(string:"https://api.github.com/search/repositories?q=\(currentQuery)")!) - let decodedResponse = try JSONDecoder().decode(RepositoriesResponse.self, from: data) - - state.repositories = decodedResponse.repositories - state.isLoading = false - - logger.debug("search repositories success: \(String(describing: decodedResponse.repositories.count))") - } - catch { - logger.error("error while searching repositories: \(error)") - } - - case .onSortOptionSelected(let option): - state.sortBy = option - UserDefaults.standard.set(option.rawValue, forKey: "sortBy") - } - } - - func action(_ action: SyncAction) { - switch action { - case .toggleHidePrivate: - state.hidePrivate.toggle() - } - } - - private func handleSortOption(_ value: String) { - state.sortBy = SortOptions(rawValue: value)! - } - - deinit { - logger.debug("deinit RepositorySearchReactor") - } -} diff --git a/Example/AsyncReactorExample/Features/Repository/Search/RepositorySearchView.swift b/Example/AsyncReactorExample/Features/Repository/Search/RepositorySearchView.swift deleted file mode 100644 index e979d5e..0000000 --- a/Example/AsyncReactorExample/Features/Repository/Search/RepositorySearchView.swift +++ /dev/null @@ -1,88 +0,0 @@ -// -// RepositorySearchView.swift -// AsyncReactorExample -// -// Created by Ahmet Bozkan on 22.05.23. -// - -import SwiftUI -import AsyncReactor -import Combine - -struct RepositorySearchView: View { - @EnvironmentObject - private var reactor: RepositorySearchReactor - - @ActionBinding(RepositorySearchReactor.self, keyPath: \.hidePrivate, action: RepositorySearchReactor.SyncAction.toggleHidePrivate) - private var hidePrivate: Bool - - @ActionBinding(RepositorySearchReactor.self, keyPath: \.query, cancelId: .init(id: "enterQuery", mode: .inFlight), action: RepositorySearchReactor.Action.enterQuery) - private var query: String - - @ActionBinding(RepositorySearchReactor.self, keyPath: \.sortBy, action: RepositorySearchReactor.Action.onSortOptionSelected) - private var sortOption: SortOptions - - var body: some View { - NavigationStack { - List { - Toggle("Hide Private Repos", isOn: $hidePrivate) - - if reactor.isLoading { - HStack { - Spacer() - ProgressView().id(UUID()) - Spacer() - } - .padding() - } - - if !reactor.repositories.isEmpty { - RepositoryList( - repositories: reactor.repositories - .filter { - !hidePrivate || $0.isVisible - } - .sorted(by: { - switch sortOption { - case .watchers: - return $0.watchersCount < $1.watchersCount - case .forks: - return $0.forks < $1.forks - } - }) - ) - } - } - .navigationTitle("Repositories") - .refreshable { - reactor.send(.load) - } - .searchable(text: $query) - .toolbar { - ToolbarItem { - Menu("Sort By") { - Picker("Sort By", selection: $sortOption) { - ForEach(SortOptions.allCases) { - Text($0.displayName) - } - } - } - } - } - .navigationDestination(for: Repository.self) { repository in - ReactorView(RepositoryDetailReactor()) { - RepositoryDetailView(repository: repository) - } - } - } - } -} - -struct RepositorySearchView_Previews: PreviewProvider { - static var previews: some View { - ReactorView(RepositorySearchReactor()) { - RepositorySearchView() - } - } -} - diff --git a/Example/AsyncReactorExample/Models/Repository.swift b/Example/AsyncReactorExample/Models/Repository.swift deleted file mode 100644 index 4e42661..0000000 --- a/Example/AsyncReactorExample/Models/Repository.swift +++ /dev/null @@ -1,62 +0,0 @@ -// -// Github.swift -// AsyncReactorExample -// -// Created by Ahmet Bozkan on 22.05.23. -// - -import Foundation - -struct Repository: Decodable, Identifiable, Hashable { - var id: Int - let name: String - let fullName: String - let description: String? - let htmlUrl: String - let watchersCount: Int - let forks: Int - - let visibility: String - var isVisible: Bool { - if visibility.lowercased() == "public" { - return true - } - else { - return false - } - } - - var owner: Owner - - struct Owner: Decodable, Hashable { - var avatarUrl: String - - enum CodingKeys: String, CodingKey { - case avatarUrl = "avatar_url" - } - } - - enum CodingKeys : String, CodingKey { - case id - case name - case fullName = "full_name" - case description - case htmlUrl = "html_url" - case visibility - case owner - case watchersCount = "watchers_count" - case forks - } -} - -struct RepositoriesResponse: Decodable { - let totalCount: Int - let repositories: [Repository] - var nextPage: URL? - - private enum CodingKeys: String, CodingKey { - case totalCount = "total_count" - case repositories = "items" - case nextPage = "next_page" - } -} diff --git a/Example/AsyncReactorExample/ObservableTestView.swift b/Example/AsyncReactorExample/ObservableTestView.swift deleted file mode 100644 index ac885c7..0000000 --- a/Example/AsyncReactorExample/ObservableTestView.swift +++ /dev/null @@ -1,76 +0,0 @@ -// -// ObservableTestView.swift -// AsyncReactorExample -// -// Created by Dominik Arnhof on 21.11.24. -// - -import SwiftUI -import Reactor - -@available(iOS 17.0, *) -@Observable -class ObservableTestReactor: Reactor { - enum SyncAction { - case count - case enterText(String) - } - - @Observable - class State { - var count = 0 - var text = "test" - } - - private(set) var state = State() - - init(state: State = State()) { - self.state = state - print("reactor init") - } - - func action(_ action: SyncAction) { - switch action { - case .count: - state.count += 1 - case .enterText(let text): - state.text = text - } - } -} - -@available(iOS 17.0, *) -struct ObservableTestView: View { - @Environment(ObservableTestReactor.self) - private var reactor - - @ActionBinding(ObservableTestReactor.self, keyPath: \.text, action: ObservableTestReactor.SyncAction.enterText) - private var text: String - - var body: some View { - let _ = Self._printChanges() - VStack { - Text(reactor.count.formatted()) - - Button { - reactor.action(.count) - } label: { - Text("+") - } - - Text(reactor.text) - - TextField("Text", text: $text) - .textFieldStyle(.roundedBorder) - .padding() - } - } -} - -#Preview { - if #available(iOS 17.0, *) { - ReactorView(ObservableTestReactor()) { - ObservableTestView() - } - } -} diff --git a/Example/AsyncReactorExample/Preview Content/Preview Assets.xcassets/Contents.json b/Example/AsyncReactorExample/Preview Content/Preview Assets.xcassets/Contents.json deleted file mode 100644 index 73c0059..0000000 --- a/Example/AsyncReactorExample/Preview Content/Preview Assets.xcassets/Contents.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "info" : { - "author" : "xcode", - "version" : 1 - } -} diff --git a/README.md b/README.md index d9df5cb..88f3370 100644 --- a/README.md +++ b/README.md @@ -174,7 +174,7 @@ class RepositorySearchReactor: AsyncReactor { ``` ## Example -An example can be found in the [Example](./Example/AsyncReactorExample) folder. +Example implementation can be found [here](https://github.com/diamirio/AsyncReactor-Example). ## License ```