Skip to content

Commit

Permalink
Merge pull request #72 from RotBolt/task/update-docs-information
Browse files Browse the repository at this point in the history
Update docs for flaker-android v0.1.0
  • Loading branch information
RotBolt authored Sep 2, 2023
2 parents 227dccc + 1d7996b commit 2949256
Show file tree
Hide file tree
Showing 6 changed files with 55 additions and 14 deletions.
21 changes: 17 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,20 @@ https://github.com/RotBolt/Flaker/assets/24780524/3d00e644-0f47-4755-8402-74001f

## Getting Started

### Usage
#### Installation (In Progress - Not yet published to maven central)

Add the following dependency to your project.

```kotlin
debugImplementation("io.rotlabs:flaker-android-okhttp:${latest_version}")
releaseImplementation("io.rotlabs:flaker-android-okhttp-no-op:${latest_version}")
```

**_NOTE:_** It is not yet published to maven central. But you can download all the modules from [github packages](https://github.com/RotBolt?tab=packages&repo_name=Flaker) and add them to your project for now.

#### flaker-android-okhttp
Add the following statement to your app's onCreate method.
```kotlin

```kotlin
class MainApplication: Application() {
override fun onCreate() {
super.onCreate()
Expand All @@ -39,12 +47,17 @@ Then in your okhttp client builder, add the following interceptor.
.build()
```

#### flaker-android-ktor (In Progress)

#### flaker-ios-ktor (In Progress)

That's it. Now you can use the companion app to simulate the network conditions.

## Development

### Library Code Map
![library-code-map.png](docs/assets/library-code-map.png)
![library-code-map.png](docs/assets/library-code-map.png#gh-light-mode-only)
![library-code-map.png](docs/assets/library-code-map-dark.png#gh-dark-mode-only)


### :hammer: Build
Expand Down
Binary file added docs/assets/library-code-map-dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/assets/library-code-map.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 4 additions & 2 deletions docs/development.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
## Development

### Library Code Map
![library-code-map.png](assets/library-code-map.png)
### Library Code Map
![library-code-map.png](assets/library-code-map.png#only-light)
![library-code-map.png](assets/library-code-map-dark.png#only-dark)


### 🛠️ Build
### Build
Simply clone this repository in Android Studio Giraffe or above and build the project.

### Module Details
Expand Down
18 changes: 16 additions & 2 deletions docs/getting-started.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,19 @@
# Usage

#### Installation (In Progress - Not yet published to maven central)

Add the following dependency to your project.

```kotlin
debugImplementation("io.rotlabs:flaker-android-okhttp:${latest_version}")
releaseImplementation("io.rotlabs:flaker-android-okhttp-no-op:${latest_version}")
```

**_NOTE:_** It is not yet published to maven central. But you can download all the modules from [github packages](https://github.com/RotBolt?tab=packages&repo_name=Flaker) and add them to your project for now.

#### flaker-android-okhttp
Add the following statement to your app's onCreate method.
```kotlin

```kotlin
class MainApplication: Application() {
override fun onCreate() {
super.onCreate()
Expand All @@ -19,4 +29,8 @@ Then in your okhttp client builder, add the following interceptor.
.build()
```

#### flaker-android-ktor (In Progress)

#### flaker-ios-ktor (In Progress)

That's it. Now you can use the companion app to simulate the network conditions.
24 changes: 18 additions & 6 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,25 @@ nav:
- Development: development.md
theme:
name: 'material'
logo: 'assets/logo.png'
icon:
repo: fontawesome/brands/github
favicon: 'assets/logo.png'
favicon: assets/images/icon-square.png
logo: assets/logo.png
palette:
primary: 'deep-orange'
accent: 'deep-purple'
- media: "(prefers-color-scheme: light)"
scheme: default
primary: teal
accent: blue
toggle:
icon: octicons/sun-24
name: "Switch to Dark Mode"
- media: "(prefers-color-scheme: dark)"
scheme: slate
primary: teal
accent: blue
toggle:
icon: octicons/moon-24
name: "Switch to Light Mode"
features:
- navigation.tabs
markdown_extensions:
- attr_list
- md_in_html
Expand Down

0 comments on commit 2949256

Please sign in to comment.