Posts
Q&A
ํ์ด์ด๋ฒ ์ด์ค ์ฝ๋๋ฅผ ๋ฃ๊ณ ์คํํ์๋ง์ ํ๊ฒจ์
build gradle(module)์plugins { id 'com.android.application' id 'org.jetbrains.kotlin.android' //id 'com.google.gms.google-services' } android { namespace 'com.example.FoodAdventure' compileSdk 33 defaultConfig { applicationId "com.example.FoodAdventure" minSdk 24 targetSdk 33 versionCode 1 versionName "1.0" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' } } compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } kotlinOptions { jvmTarget = '1.8' } buildFeatures { viewBinding true } } dependencies { implementation 'androidx.core:core-ktx:1.8.0' implementation 'androidx.appcompat:appcompat:1.6.1' implementation 'com.google.android.material:material:1.5.0' implementation 'androidx.constraintlayout:constraintlayout:2.1.4' implementation 'com.android.identity:identity-credential:+' implementation 'com.google.android.gms:play-services-maps:18.1.0' testImplementation 'junit:junit:4.13.2' androidTestImplementation 'androidx.test.ext:junit:1.1.5' androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1' implementation platform('com.google.firebase:firebase-bom:32.1.1') implementation 'com.google.firebase:firebase-analytics-ktx' implementation 'com.google.firebase:firebase-auth-ktx:21.0.3' //implementation 'com.google.firebase:firebase-auth-ktx:22.0.0' }
- 1
- 4
- 1.2K
Q&A
ํ์ด์ด๋ฒ ์ด์ค ์ฝ๋๋ฅผ ๋ฃ๊ณ ์คํํ์๋ง์ ํ๊ฒจ์
build gradle(project)๋buildscript { repositories { google() // Google's Maven repository mavenCentral() // Maven Central repository } } plugins { id 'com.android.application' version '8.0.2' apply false id 'com.android.library' version '8.0.2' apply false id 'org.jetbrains.kotlin.android' version '1.8.20' apply false id 'com.google.gms.google-services' version '4.3.10' apply false }
- 1
- 4
- 1.2K
Q&A
ํ์ด์ด๋ฒ ์ด์ค ์ฝ๋๋ฅผ ๋ฃ๊ณ ์คํํ์๋ง์ ํ๊ฒจ์
์ผ๋จ ์ฝ๋๋ ์๋ ์ฒ๋ผ ๋ผ์๊ตฌ์.package com.example.FoodAdventure.Activity import android.content.ContentValues.TAG import android.content.Intent import androidx.appcompat.app.AppCompatActivity import android.os.Bundle import android.util.Log import android.widget.Toast import com.example.FoodAdventure.databinding.ActivityLoginBinding import com.google.firebase.auth.FirebaseAuth import com.google.firebase.auth.ktx.auth import com.google.firebase.ktx.Firebase class LoginActivity : AppCompatActivity() { private lateinit var binding: ActivityLoginBinding private lateinit var auth: FirebaseAuth override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) binding = ActivityLoginBinding.inflate(layoutInflater) val view = binding.root setContentView(view) auth = Firebase.auth } }
- 1
- 4
- 1.2K
Q&A
ํ์ด์ด๋ฒ ์ด์ค gradle์ค์ ์์ ์๋ฌ๊ฐ๋์์
์~ ์ด๊ฑด ์ง๋ฌธ๊ธ์ ์ฌ๋ผ์์๋ ๊ธ์ ๋ณด๊ณ ํด๊ฒฐํ์ต๋๋ค!path๋์ ์ plugin ์์์๋ ์ฝ๋๋ฅผ ๋ฃ์ด์ ํด๊ฒฐํ์ต๋๋ค. id 'com.google.gms.google-services' version '4.3.10' apply false
- 0
- 2
- 1.2K
Q&A
ํ๋ฉด ํด๋ฆญ ์ด๋ฒคํธ ์ฒ๋ฆฌ - findViewById, Toast ์์ 07:08 ์์ ๋ฌธ์ ๊ฐ ์๊ฒผ์ต๋๋ค.
์ด๋ ๊ฒ ๋์ต๋๋ค. ImageView์๋ํ ๋ด์ฉ์ด ์์ต๋๋ค. ๊ฐ์ ธ๋ค๋๋ฉด unresolved refference: ImageView ๋ผ๊ณ ๋จ๊ตฌ์ ๊ตฌ๊ธ๋งํด์ ์ฐพ์๋ณด๋๊น ๋น์ทํ ์ฌ๋ก๊ฐ ์์ด์ ๊ทธ๊ฑฐ๋ณด๊ณ gradle์ ๋ค์ด๊ฐ์ id 'kotlin-android-extensions' ์ด๊ฒ๋ ํด๋ดค๋๋ฐ ์๋๋ค์.. (์ฌ์ง)
- 0
- 3
- 377