Skip to content
Back to skills

Bootstrap

ASecurity

Bootstrap — responsive grid for legacy, server-rendered, WordPress.

  • 6 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added September 6, 2026
developmentreactvueapidocumentation

Works with

  • cli
  • api
  • mcp

Security analysis

A100/100

Scanned September 6, 2026

npx -y skills add Dev-Toolbelt/dev-team-agents --skill bootstrap --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Bootstrap?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Bootstrap
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/dev-toolbelt-bootstrap/badge)](https://www.skillsdirectory.com/skills/dev-toolbelt-bootstrap)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: bootstrap
description: Bootstrap — responsive grid for legacy, server-rendered, WordPress.
---

## Detection Signals

- `bootstrap` in `package.json` OR `bootstrap` CSS/JS in HTML `<link>`/`<script>` tags
- `react-bootstrap` or `bootstrap-vue` packages
- `data-bs-*` attributes in HTML elements
- `.container`, `.row`, `.col-*` class patterns
- `.btn`, `.card`, `.modal`, `.navbar`, `.dropdown` class patterns

## MCP Setup

No official MCP server is available for Bootstrap.

> Reference the Bootstrap 5 docs at [getbootstrap.com/docs](https://getbootstrap.com/docs/5.3/). Configure a documentation search MCP in your CLI's settings if one is available.

## Core Concepts

| Concept | Detail |
|---------|--------|
| **12-column grid** | `.container` → `.row` → `.col-*` — always nest in this order |
| **Breakpoints** | `xs` (<576px), `sm` (576px), `md` (768px), `lg` (992px), `xl` (1200px), `xxl` (1400px) |
| **Utility classes** | Spacing `m-*/p-*`, display `d-*`, flex `d-flex/gap-*`, text `text-*`, color `text-*/bg-*` |
| **JS components** | Modal, dropdown, tooltip, collapse require Bootstrap's JS bundle or `data-bs-*` API |
| **Sass variables** | The canonical way to customize Bootstrap before its CSS is compiled |

## Component Patterns

```html
<!-- Grid — always: container → row → col -->
<div class="container">
  <div class="row g-3">
    <div class="col-12 col-md-6 col-lg-4">Content</div>
  </div>
</div>

<!-- Buttons -->
<button class="btn btn-primary">Primary</button>
<button class="btn btn-outline-secondary btn-sm">Small outline</button>

<!-- Modal — via data attributes, no JS needed for trigger -->
<button data-bs-toggle="modal" data-bs-target="#confirmModal">Open</button>
<div class="modal fade" id="confirmModal" tabindex="-1">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header">...</div>
      <div class="modal-body">...</div>
    </div>
  </div>
</div>
```

## React Bootstrap Pattern

When `react-bootstrap` is present, use components — not raw class strings:

```tsx
import { Button, Modal, Container, Row, Col } from 'react-bootstrap'

// Correct — component manages refs and ARIA
<Button variant="primary" size="sm" onClick={handleClick} />

// Wrong — bypasses react-bootstrap's event and ref management
<button className="btn btn-primary btn-sm" onClick={handleClick} />
```

## Version Check

**Bootstrap 4 vs 5** — APIs differ. Confirm version in `package.json` before writing classes:
- Spacing: `ml-*`/`mr-*` (v4) → `ms-*`/`me-*` (v5)
- Flex gap: not available in v4
- Grid: `.row-cols-*` added in v5

## Critical Rules

- **Never mix Bootstrap grid with a custom grid** — pick one layout system per project
- **Use Bootstrap spacing utilities** — `m-*/p-*/gap-*` consistently; don't introduce arbitrary pixel values that break the spacing rhythm
- **Interactive components need Bootstrap JS** — modal, dropdown, tooltip, and collapse won't function without the JS bundle or Popper.js
- **React projects: use `react-bootstrap`** — raw HTML + class strings bypass ref and ARIA management
- **Customize via Sass variables** — overriding Bootstrap CSS with higher specificity causes maintenance problems; set `$primary: #yourcolor` before the Bootstrap import

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.