本文へスキップ
Skillpedia
WebサイトとUI(フロントエンド)75k · #2982

preconnect

できること

このスキルは、ページのheadにあるpreconnectヒントを確認し、外部ドメインへのヒントの追加や削除を提案します。フォント、APIなどのサードパーティのサービスから速く読み込みたい制作者向けです。

使う場面

  • ✓フォントや他の外部サービスへの接続を速めるようエージェントに頼むとき。
  • ✓読み込みの早い段階でサードパーティのドメインを待っていて、ヒントが効くか確かめたいとき。
  • ✓ページに多くのpreconnectヒントがあり、使われていないものを取り除きたいとき。

スキルのリンク

https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/preconnect/SKILL.md

コピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。

使い方

いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。

貼り付け用メッセージ

このスキルを使って手伝ってください:https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/preconnect/SKILL.md このリンクのSKILL.mdファイルを読んで、私の作業でその指示に従ってください。
こういうスキルを、AIが自分で見つけてくれたら?無料のSkillpedia MCPをインストール。1行で、作業の前に15,000+のスキルから探してくれます。1分でインストール →

AIへの頼み方の例

“私のページは、フォントのサービスとAPIを待ってから表示されます。重要なものにpreconnectヒントを追加してください。”

毎週5つの新しいスキル。1分で読めます。

仕組み

エージェントはheadセクションの既存のpreconnectヒントを確認し、ページが依存する重要な外部オリジンを特定します。最も重要なものにヒントを追加し、使われていないドメインのヒントは取り除きます。

技術的な内容(元のSKILL.md)

作者による元のテキスト(英語)をGitHubからそのまま表示しています。

Use preconnect for critical third-party origins

Preconnecting to essential origins can shave hundreds of milliseconds off the critical path by handling connection overhead ahead of time.

Quick Reference

  • Establish early connections to important third-party domains (e.g., fonts, APIs)
  • Reduce latency by performing DNS lookup, TCP handshake, and TLS negotiation early
  • Avoid overusing preconnect; limit to 2-4 most critical origins

Check

Review the page's head for preconnect hints and identify any missing or unnecessary connections to third-party domains.

Fix

Add <link rel="preconnect"> for critical third-party origins and remove it for non-essential or underutilized domains.

Explain

Explain how preconnect helps reduce the time spent on connection overhead for third-party resources.

Code Review

Review the routes, assets, and loading behavior that affect Use preconnect for critical third-party origins. Flag exact files, requests, or rendering steps that add unnecessary network, CPU, or layout cost, and describe the measurement method used to confirm the issue.


For full implementation details, code examples, and framework-specific guidance, see references/rule.md.

Rule page: https://frontendchecklist.io/rules/performance/preconnect

よくある質問

preconnectは実際に何をしますか?

ブラウザーがドメインを調べ、接続を開き、安全なハンドシェイクを完了してから、ファイルを要求できるようにします。

ページには何個のpreconnectヒントを置くべきですか?

このスキルは、最も重要な2から4つのオリジンに限定することを勧めています。

変更は確かめるべきですか?

はい。このスキルは、まずDevTools、Lighthouse、または実際の利用データで本当のボトルネックを確認することを勧めています。

詳細

作者による元の説明

Use when auditing slow page loads, heavy assets, or rendering delays related to Use preconnect for critical third-party origins. Verify the actual bottleneck in DevTools, Lighthouse, or field data before recommending changes.

repo: thedaviddias/Front-End-Checklist

人気

GitHubのスター
75k
ランキング
#2982
ライセンス
MIT
更新日
2026/10/31

このスキルは役に立ちますか?

0

ログイン して投票しましょう。

コメント

  • …

このリポジトリの他のスキル

似ているスキル