Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kotlin: adding Cognito Flutter mobile app #6256

Merged

Conversation

AMZ-brandon
Copy link
Contributor

This pull request adds an Amazon Cognito example app for Android in Flutter and Kotlin. This app is part of a documentation update for the Cognito developer guide. @bhatti is primary contributor.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@github-actions github-actions bot added the Kotlin This issue relates to the AWS SDK for Kotlin label Mar 18, 2024
Copy link
Contributor

@scmacdon scmacdon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only comment I have is to move this larger example to kotlin/usecases.

@AMZ-brandon
Copy link
Contributor Author

Only comment I have is to move this larger example to kotlin/usecases.

@scmacdon Done!

@AMZ-brandon
Copy link
Contributor Author

@scmacdon do you have any recommendations to get past this error?
/github/workspace/kotlin/usecases/cognito_flutter_mobile_app/android/app/src/main/kotlin/com/example/android-app/MainActivity.kt:4:28: Not a valid Kotlin file (4:28 expecting a top level declaration) (cannot be auto-corrected) ()

The app works, so I'm hoping there's an easy way to remedy this. Also @bhatti for any ideas.
File contents:

// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0

package com.example.android-app

import io.flutter.embedding.android.FlutterActivity

class MainActivity : FlutterActivity() { /*...*/ }

@bhatti
Copy link
Contributor

bhatti commented Mar 21, 2024

@AMZ-brandon , I am not quite following the cause of kotlin error as that file was generated by flutter tooling and is a valid kotlin file. The developers of flutter generally use dart for the application logic and flutter tooling generates scaffolding for target platform. As, flutter project includes multiple languages including kotlin, dart, objective-c, c++, etc so it probably needs its own folder under dart. Let me know what you think.

@AMZ-brandon AMZ-brandon force-pushed the Cognito_Flutter_Kotlin_Mobile_App branch from 6c25b4c to 44af510 Compare March 25, 2024 16:52
@AMZ-brandon AMZ-brandon force-pushed the Cognito_Flutter_Kotlin_Mobile_App branch from eb1e8b0 to 44af510 Compare April 1, 2024 21:58
@scmacdon scmacdon added On Call Review needed This work needs an on-call review Application An example with multiple AWS Services and SDKs to show how to build a complete, working application. labels Apr 2, 2024
@cpyle0819 cpyle0819 added On Call Review complete On call review complete and removed On Call Review needed This work needs an on-call review labels Apr 2, 2024
@cpyle0819 cpyle0819 force-pushed the Cognito_Flutter_Kotlin_Mobile_App branch from 086eab0 to b2a784d Compare April 2, 2024 13:19
@cpyle0819 cpyle0819 merged commit 5548e05 into awsdocs:main Apr 2, 2024
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Application An example with multiple AWS Services and SDKs to show how to build a complete, working application. Kotlin This issue relates to the AWS SDK for Kotlin On Call Review complete On call review complete
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants