Skip to content

Commit

Permalink
feat: 데모앱 구현
Browse files Browse the repository at this point in the history
  • Loading branch information
chansooo committed Jun 29, 2024
1 parent 8573819 commit 72bd776
Show file tree
Hide file tree
Showing 4 changed files with 116 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Projects/App/Project.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,12 @@ let project = Project.configure(
name: "Release-Farmeme",
product: .app,
bundleId: "ppac.farmeme.App",
// infoPlist: .extendingDefault(with: <#T##[String : Plist.Value]#>),
infoPlist: .extendingDefault(with: [
"CFBundleShortVersionString": "1.0",
"CFBundleVersion": "1",
"UIMainStoryboardFile": "",
"UILaunchStoryboardName": "LaunchScreen"
]),
sources: "Sources/**",
resources: "Resources/**",
dependencies: [
Expand Down
52 changes: 52 additions & 0 deletions Projects/DemoApp/Project.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
//
// Project.swift
// ProjectDescriptionHelpers
//
// Created by kimchansoo on 6/29/24.
//

import Foundation

import ProjectDescription
import ProjectDescriptionHelpers

let project = Project.configure(
name: "DemoApp",
packages: [
],
targets: [
.configure(
name: "DemoApp",
product: .app,
bundleId: "ppac.farmeme.DemoApp",
infoPlist: .extendingDefault(with: [
"CFBundleShortVersionString": "1.0",
"CFBundleVersion": "1",
"UIMainStoryboardFile": "",
"UILaunchStoryboardName": "LaunchScreen"
]),
sources: "Sources/**",
resources: "Resources/**",
dependencies: [
.Feature.Home,
.Feature.Recommend,
.Feature.Search,
.Feature.MyPage,
.ResourceKit,
.Core.DesignSystem,
.Core.PPACNetwork,
.ThirdParty.Lottie,
.ThirdParty.Dependency,
],
settings: .settings(
base: [
"DEVELOPMENT_TEAM": "4NV4Z6BW27",
"CODE_SIGN_STYLE": "Manual",
"PROVISIONING_PROFILE_SPECIFIER": "match AppStore ppac.farmeme.App",
"CODE_SIGN_IDENTITY": "Apple Distribution: Chansoo Kim (4NV4Z6BW27)"
]
// defaultSettings: .recommended(excluding: [])
)
)
]
)
1 change: 1 addition & 0 deletions Projects/DemoApp/Resources/Dummy.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
// dummy임니다
57 changes: 57 additions & 0 deletions Projects/DemoApp/Sources/DemoApp.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
//
// DemoApp.swift
// App
//
// Created by kimchansoo on 6/1/24.
// Copyright © 2024 ppac.farmeme. All rights reserved.
//

import SwiftUI
import Home
import MemeDetail

@main
struct DemoApp: App {

enum Views: String, CaseIterable, Identifiable {
case MemeDetail

var id: String { self.rawValue }

var view: some View {
switch self {
case .MemeDetail:
getMemeDetailView()
}
}
}

@State private var selectedView: Views? = nil

var body: some Scene {
WindowGroup {
NavigationView {
List(Views.allCases) { view in
NavigationLink(destination: view.view) {
Text(view.rawValue)
}
}
.navigationTitle("Views")
.background(.blue)
}
}
}
}

private extension DemoApp.Views {
func getMemeDetailView() -> some View {
return MemeDetailView(
viewModel: MemeDetailViewModel(
meme: .mock,
router: nil,
copyImageUseCase: CopyImageUseCaseImpl(),
postLikeUseCase: PostLikeUseCaseImpl()
)
)
}
}

0 comments on commit 72bd776

Please sign in to comment.