0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Astro + Cloudflare Pages で静的 Big Five 性格診断を出した実装メモ

0
Posted at

単機能の日本語ウェブサービスを、会員登録なし・回答をサーバーに送らない前提で静的配信したメモです。デモ:https://seikaku-test.com (娯楽向け・非臨床)

要件

  • 30問・5件法
  • Big Five(E/A/C/N/O)
  • クライアント採点
  • Cloudflare Pages で dist/ 配信

題庫

src/data/questions.json に meta(尺度・次元文言)と questions を置き、Astro ビルド時に埋め込み。逆転項目は keyed: plus|minus で扱う。

画面

  • /quiz/:進捗バー + radiogroup。完了後に正規化スコアをクエリへ載せて /result/ へ
  • /result/:棒グラフ相当のスコアリスト、共有テキスト、X intent。クエリ欠け時は再診断導線

例:/result/?e=58&a=54&c=54&n=33&o=42

なぜこの形か

登録基盤が不要/POST しない設計に寄せやすい/薄 MVP 向き。結果 URL が改ざん可能な点は娯楽用途で許容。

デプロイ

npm run build
# Pages: dist を Direct Upload または wrangler pages deploy

あわせて robots / sitemap / プライバシー・利用規約・問い合わせ・非臨床免責を静的でも落とさない。

まとめ

Astro + JSON 題庫 + クライアント採点 + Pages は、計算系・チェックリスト系の単機能ツールにも横展開しやすいです。

連絡:admin@seikaku-test.com

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?