@rulepack/django

v0.1.0

Official Django coding style, ORM query optimization (select_related/prefetch_related), and security rules for AI agents.

Updated 6/4/20266 files | 10.6 KB
$pnpm dlx rulepack add django

Drops CLAUDE.md / .cursor/rules/* and friends into your project.

Downloads

0

Stars

0

Views

0

django

Rules for AI coding agents based on Django's official coding style, ORM query optimization, and security guidance.

npx rulepack add django

What it covers

  • CLAUDE.md — Claude Code playbook: style, imports, models & ORM, views, security, and a "Don't" list.
  • AGENTS.md — universal agent spec condensed to the load-bearing rules.
  • .cursor/rules/django.mdc — Cursor rules for the same scope (**/*.py).

Highlights: black/isort formatting and import order, model field/method ordering, select_related vs prefetch_related to kill N+1 queries, lazy/cached QuerySets and bulk operations, ORM-only SQL safety, and the production security baseline (CSRF, auto-escaping, ALLOWED_HOSTS, HTTPS/HSTS, secret SECRET_KEY, DEBUG = False).

Source

License

MIT