公開 BCDice-API サーバにアクセスして、提供されている BCDice-API ・ BCDice 本体 のバージョンと、サーバの管理者情報を取得し、一覧します。
- 公開サーバリスト から、サーバのリストを取得する
- 取得した一覧に含まれる各 API サーバにアクセスし、必要な情報を取ってくる
- 一覧する
koi-chan (@koichan779)
A web page that lists statuses of public BCDice-API servers.
Home Page: https://api-status.bcdice.org
License: MIT License
公開 BCDice-API サーバにアクセスして、提供されている BCDice-API ・ BCDice 本体 のバージョンと、サーバの管理者情報を取得し、一覧します。
koi-chan (@koichan779)
最新バージョンと同じバージョンを使っているとき、バージョン番号を太字にする機能がある。
現在の実装では、バージョン番号をもとにした class を追加した上で、最新バージョン番号に付与した class に対して動的に CSS を追加している。
→全て非同期で API アクセスを行なっているため。また、バージョン同士の比較をコードで行なわなくて済む。
ロジックと見た目の定義を分離するため、CSS で固定の太字にする装飾を行ない、最新バージョンの場合は該当の class を動的に追加して太字にするよう、変更する。
これに伴い、最新バージョンが取得出来たかどうかを判断してから、BCDice-API へのアクセスを行なうようにする。
Chrome 環境において、応答時間に小数点以下が表示される。
performance.now を使って計算しているため、(少なくても現状では)精度的に意味がない。
https://developer.mozilla.org/ja/docs/Web/API/Performance/now
実用上、小数点以下第1位を四捨五入して、整数に丸める。
現在は、index.html に全てが含まれている。
HTML, JS, CSS を別ファイルに切り出した方が、メンテナンス性が上がるのではないか。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.