PHPackages                             fightmaster/fightmaster-bootstrap-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. fightmaster/fightmaster-bootstrap-bundle

ActiveSymfony-bundle

fightmaster/fightmaster-bootstrap-bundle
========================================

18JavaScript

Since Aug 19Pushed 13y ago1 watchersCompare

[ Source](https://github.com/fightmaster/FightmasterBootstrapBundle)[ Packagist](https://packagist.org/packages/fightmaster/fightmaster-bootstrap-bundle)[ RSS](/packages/fightmaster-fightmaster-bootstrap-bundle/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

2.0 BOOTSTRAP JS PHILOSOPHY
---------------------------

[](#20-bootstrap-js-philosophy)

These are the high-level design rules which guide the development of Bootstrap's plugin apis.

---

### DATA-ATTRIBUTE API

[](#data-attribute-api)

We believe you should be able to use all plugins provided by Bootstrap purely through the markup API without writing a single line of JavaScript. This is Bootstrap's first class API.

We acknowledge that this isn't always the most performant and it may sometimes be desirable to turn this functionality off altogether. Therefore, as of 2.0 we provide the ability to disable the data attribute API by unbinding all events on the body namespaced with `'data-api'`. This looks like this:

```
$('body').off('.data-api')

```

To target a specific plugin, just include the plugins name as a namespace along with the data-api namespace like this:

```
$('body').off('.alert.data-api')

```

---

### PROGRAMATIC API

[](#programatic-api)

We also believe you should be able to use all plugins provided by Bootstrap purely through the JavaScript API.

All public APIs should be single, chainable methods, and return the collection acted upon.

```
$(".btn.danger").button("toggle").addClass("fat")

```

All methods should accept an optional options object, a string which targets a particular method, or null which initiates the default behavior:

```
$("#myModal").modal() // initialized with defaults
$("#myModal").modal({ keyboard: false }) // initialized with no keyboard
$("#myModal").modal('show') // initializes and invokes show immediately

```

---

### OPTIONS

[](#options)

Options should be sparse and add universal value. We should pick the right defaults.

All plugins should have a default object which can be modified to affect all instances' default options. The defaults object should be available via `$.fn.plugin.defaults`.

```
$.fn.modal.defaults = { … }

```

An options definition should take the following form:

```
*noun*: *adjective* - describes or modifies a quality of an instance

```

Examples:

```
backdrop: true
keyboard: false
placement: 'top'

```

---

### EVENTS

[](#events)

All events should have an infinitive and past participle form. The infinitive is fired just before an action takes place, the past participle on completion of the action.

```
show | shown
hide | hidden

```

All infinitive events should provide preventDefault functionality. This provides the abililty to stop the execution of an action.

```
$('#myModal').on('show', function (e) {
    if (!data) return e.preventDefault() // stops modal from being shown
})

```

---

### CONSTRUCTORS

[](#constructors)

Each plugin should expose its raw constructor on a `Constructor` property -- accessed in the following way:

```
$.fn.popover.Constructor

```

---

### DATA ACCESSOR

[](#data-accessor)

Each plugin stores a copy of the invoked class on an object. This class instance can be accessed directly through jQuery's data API like this:

```
$('[rel=popover]').data('popover') instanceof $.fn.popover.Constructor

```

---

### DATA ATTRIBUTES

[](#data-attributes)

Data attributes should take the following form:

- data-{{verb}}={{plugin}} - defines main interaction
- data-target || href^=# - defined on "control" element (if element controls an element other than self)
- data-{{noun}} - defines class instance options

Examples:

```
// control other targets
data-toggle="modal" data-target="#foo"
data-toggle="collapse" data-target="#foo" data-parent="#bar"

// defined on element they control
data-spy="scroll"

data-dismiss="modal"
data-dismiss="alert"

data-toggle="dropdown"

data-toggle="button"
data-toggle="buttons-checkbox"
data-toggle="buttons-radio"

```

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/1c9c8c25d979f415e12cb7bf5281570afb86ebe6c7fe419a1aef8a858920d2a4?d=identicon)[fightmaster](/maintainers/fightmaster)

---

Top Contributors

[![fightmaster](https://avatars.githubusercontent.com/u/648770?v=4)](https://github.com/fightmaster "fightmaster (2 commits)")

### Embed Badge

![Health badge](/badges/fightmaster-fightmaster-bootstrap-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/fightmaster-fightmaster-bootstrap-bundle/health.svg)](https://phpackages.com/packages/fightmaster-fightmaster-bootstrap-bundle)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
