-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
87 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# cloudflare-ip-tester-app | ||
|
||
### Inspired by | ||
|
||
- [CloudflareSpeedTest](https://github.com/XIU2/CloudflareSpeedTest) | ||
- [cloudflare-ip-tester](https://github.com/TulvL/cloudflare-ip-tester) | ||
|
||
### Functions | ||
|
||
- test cloudflare-ip as many as you want | ||
|
||
|
||
- generate a history statistics based on your test results. | ||
|
||
<div style="display: flex;flex-flow:row wrap;"> | ||
<img src="./assets/images/test-run-min.jpg" height="600"> | ||
<img src="./assets/images/test-statistics-min.jpg" height="600"> | ||
</div> | ||
|
||
### MIT License |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import { useState } from "react"; | ||
export enum TestRunningStatus { | ||
Uninitialized = "Uninitialized", | ||
Running = "Running", | ||
} | ||
const nextTestRunningStatusMap = { | ||
[TestRunningStatus.Uninitialized]: TestRunningStatus.Running as const, | ||
[TestRunningStatus.Running]: TestRunningStatus.Uninitialized as const, | ||
}; | ||
export function useTestRunningStatus() { | ||
const [testRunningStatus, setTestRunningStatus] = | ||
useState<`${TestRunningStatus}`>(TestRunningStatus.Uninitialized); | ||
|
||
function nextTestRunningStatus() { | ||
setTestRunningStatus((prev) => { | ||
return nextTestRunningStatusMap[prev]; | ||
}); | ||
} | ||
|
||
return { | ||
testRunningStatus, | ||
nextTestRunningStatus, | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import { StyleSheet } from "react-native"; | ||
export const miniStyle = StyleSheet.create({ | ||
textStyle: { | ||
fontSize: 12, | ||
}, | ||
}); |