Back to Skills

cdn-usage

dave1010
Updated Today
11 views
0
View on GitHub
Designdesign

About

This Claude Skill provides CDN selection guidance when adding external browser dependencies. It recommends jsDelivr as the default choice with npm syntax for automatic semver resolution, and includes reliability tips like avoiding integrity hashes that LLMs often get wrong. Use this skill whenever you need to load scripts via CDN to ensure robust dependency loading.

Documentation

CDNs (if needed)

  • UMD is probably best, unkess you're composing multiple modern packages and know they expose export syntax.
  • Skip integrity hashes (LLMs get them wrong)
  • LLM training data may get URLs wrong. Add onerror="alert('Failed to load: ' + this.src)"

jsDelivr

Example:

<script type="module">
import duckdbduckdbWasm from 'https://cdn.jsdelivr.net/npm/@duckdb/[email protected]/+esm'
</script>

cdnjs

esm.sh

  • Use for live ESM transforms, not static files. Transforms TS/TSX on the fly.
  • Eg import * as THREE from "https://esm.sh/[email protected]";
  • tsx mode: load https://esm.sh/tsx as a module → inline <script type="text/tsx">

Quick Install

/plugin add https://github.com/dave1010/tools/tree/main/cdn-usage

Copy and paste this command in Claude Code to install this skill

GitHub 仓库

dave1010/tools
Path: .skills/cdn-usage

Related Skills

langchain

Meta

LangChain is a framework for building LLM applications using agents, chains, and RAG pipelines. It supports multiple LLM providers, offers 500+ integrations, and includes features like tool calling and memory management. Use it for rapid prototyping and deploying production systems like chatbots, autonomous agents, and question-answering services.

View skill

Algorithmic Art Generation

Meta

This skill helps developers create algorithmic art using p5.js, focusing on generative art, computational aesthetics, and interactive visualizations. It automatically activates for topics like "generative art" or "p5.js visualization" and guides you through creating unique algorithms with features like seeded randomness, flow fields, and particle systems. Use it when you need to build reproducible, code-driven artistic patterns.

View skill

webapp-testing

Testing

This Claude Skill provides a Playwright-based toolkit for testing local web applications through Python scripts. It enables frontend verification, UI debugging, screenshot capture, and log viewing while managing server lifecycles. Use it for browser automation tasks but run scripts directly rather than reading their source code to avoid context pollution.

View skill

requesting-code-review

Design

This skill dispatches a code-reviewer subagent to analyze code changes against requirements before proceeding. It should be used after completing tasks, implementing major features, or before merging to main. The review helps catch issues early by comparing the current implementation with the original plan.

View skill