问题
Flutter allows supporting of Kotlin language.
How can I integrate my Kotlin file with Flutter project?
There is no option to add/create a Kotlin file (in New menu) in Android Studio.
回答1:
I think the kotlin files can only be used in the platform-specific plugins. E.g. you have platform-specific implementation for both iOS and android and you can use kotlin for the Android part.
The Flutter SDK is used directly with Dart.
回答2:
Open your Android module in android so you can add your kotlin files
回答3:
Flutter does not support Kotlin and it looks it will not allow Flutter to be written in Kotlin language. The biggest advantage of using Dart language is the management of the object. It has a great garbage collector. Don't you think google developers didn't think about that before? Of course, they did. But Dart is chosen as the one language of Flutter.
来源:https://stackoverflow.com/questions/49069905/flutter-create-a-flutter-project-with-kotlin