-
Notifications
You must be signed in to change notification settings - Fork 0
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
Feat/current location nearest station #13 #18
Conversation
Deploying sophie with Cloudflare Pages
|
8a79f9d
to
605228c
Compare
const a = | ||
Math.sin(deltaLatitude / 2) * Math.sin(deltaLatitude / 2) + | ||
Math.cos(degreeToRadian(from.lat)) * | ||
Math.cos(degreeToRadian(to.lat)) * | ||
Math.sin(deltaLongitude / 2) * | ||
Math.sin(deltaLongitude / 2) | ||
|
||
const c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
公式か何かを使った複雑な計算は、コメントアウトで補足しておいたほうがわかりやすそう
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
関数に切り出してJSDoc的なの書いておきたさがある
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
関数分けるとよりわかりずらそうだったから関数にjsdocと途中計算にはコメントアウトにした
それでもよくわからないけど
close #13
backend
stationUseCase
に最寄り駅取得メソッドgetNearestStation
追加/location
追加frontend