Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/arjunjadeja/something
what you should avoid and learn from in kotlin
https://github.com/arjunjadeja/something
best-practices exception-handling exceptions jetpack-compose kotlin mistakes null-safety type-safety
Last synced: 4 months ago
JSON representation
what you should avoid and learn from in kotlin
- Host: GitHub
- URL: https://github.com/arjunjadeja/something
- Owner: ArjunJadeja
- License: apache-2.0
- Created: 2024-09-13T10:16:30.000Z (5 months ago)
- Default Branch: master
- Last Pushed: 2024-09-25T12:55:51.000Z (4 months ago)
- Last Synced: 2024-10-15T16:03:34.763Z (4 months ago)
- Topics: best-practices, exception-handling, exceptions, jetpack-compose, kotlin, mistakes, null-safety, type-safety
- Language: Kotlin
- Homepage:
- Size: 155 KB
- Stars: 21
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Something to avoid and learn
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
[![Kotlin Weekly](https://img.shields.io/badge/Kotlin%20Weekly-%23424-blue)](https://mailchi.mp/kotlinweekly/kotlin-weekly-424)
[![GitHub](https://img.shields.io/badge/GitHub-ArjunJadeja-181717?style=flat&logo=github)](https://github.com/ArjunJadeja)
![GitHub last commit](https://img.shields.io/github/last-commit/ArjunJadeja/Something)
![GitHub issues](https://img.shields.io/github/issues/ArjunJadeja/Something)
![GitHub stars](https://img.shields.io/github/stars/ArjunJadeja/Something)## π‘ About Project
This project showcases common mistakes in Kotlin programming and alternate approaches to avoid them, as well as useful learnings and techniques.
## π Quick Start
1. Clone the repository:
```
git clone https://github.com/ArjunJadeja/Something.git
```
2. Open the project in your favorite IDE.
3. Explore the `mistakes` and `learnings` folders.## π Mistakes
Here's a list of the mistakes added:
1. [Uninitialized Properties](src/main/kotlin/mistakes/UninitializedProperties.kt)
2. [Null Safety](src/main/kotlin/mistakes/NullSafety.kt)
3. [Unsafe Casting](src/main/kotlin/mistakes/UnsafeCasting.kt)
4. [Nullable Collections](src/main/kotlin/mistakes/NullableCollection.kt)
5. [Custom Getters](src/main/kotlin/mistakes/CustomGetter.kt)
6. [Lambda Variable Shadowing](src/main/kotlin/mistakes/LambdaVariableShadowing.kt)## π Learnings
Here's what we've learned so far:
1. [Using then with Modifier in Jetpack Compose](src/main/kotlin/learnings/ThenWithComposeModifier.kt)
## π Project Structure
The project is organized into `mistakes` and `learnings` folders, each containing specific examples.
```
Something/
βββ src/
β βββ main/
β βββ kotlin/
β βββ Main.kt
β βββ Something.kt
β βββ mistakes/
β β βββ CustomGetter.kt
β β βββ LambdaVariableShadowing.kt
β β βββ NullSafety.kt
β β βββ NullableCollection.kt
β β βββ UninitializedProperties.kt
β β βββ UnsafeCasting.kt
β βββ learnings/
β βββ ThenWithComposeModifier.kt
βββ .gitignore
βββ LICENSE
βββ README.md
βββ build.gradle.kts
```## π― Future Goals
The goal is to continuously learn and grow from real-world mistakes and discoveries.
## πΊοΈ Roadmap
There's no fixed roadmap for this project. The approach is to:
1. Add new learnings and mistakes as we encounter them.
2. Welcome contributions from the community.## π€ Contributing
Contributions from Kotlin developers of all experience levels are welcomed! Whether you're a beginner or an experienced developer, your contribution can help others learn.
Please check our [Contribution Guidelines](GUIDELINES.md) for more details on how to contribute.
## β Show Your Support
If you find this project helpful, please give it a star on GitHub. It helps others discover this resource!
## π Connect
Feel free to connect with me:
[Arjun Jadeja - LinkedIn](https://www.linkedin.com/in/arjun-jadeja/)
## π Additional Resources
- [Kotlin Playground](https://play.kotlinlang.org/)
- [Kotlin Official Documentation](https://kotlinlang.org/docs/home.html)
- [Kotlin Coding Conventions](https://kotlinlang.org/docs/coding-conventions.html)Happy coding, and remember: every mistake and learning is an opportunity! π
## π License
```
Copyright (C) 2024 Arjun Jadeja (arjunjadeja.com)Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License athttp://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
```