--- title: "Get Started" date: "2020-03-21" menu: "main" weight: 2 draft: false --- # Get started **You only need 1 CSS file to use BulmaBadge** ## Installation ### First, let's install the component! There are several ways to get started with BulmaBadge. {{< tabs tabTotal="3" tabID="1" tabName1="1. NPM" tabName2="2. CDN" tabName3="3. Github" >}} {{< tab tabNum="1" >}} Use npm to install the `bulma-badge` package **recommended** ```shell npm install @creativebulma/bulma-badge ``` {{< /tab >}} {{< tab tabNum="2" >}} Use the [jsDelivr](https://jsdelivr.com) CDN to link to the BulmaBadge stylesheet ```html https://www.jsdelivr.com/package/npm/@creativebulma/bulma-badge ``` {{< /tab >}} {{< tab tabNum="3" >}} Use the GitHub repository to get the latest development version. Download from the repository [https://github.com/CreativeBulma/bulma-badge/tree/master/dist/](https://github.com/CreativeBulma/bulma-badge/tree/master/dist/) {{< /tab >}} {{< /tabs >}} ## Usage Badges are displayed into a container on top of the element. All you have to do is to add a container with the `badge` class and with the text you want to display as value. ### Styles #### Default {{< preview id="default" lang="html" >}} {{< /preview >}} The badge is available in outlined style. Simply append the modifier `is-outlined` to the badge element to apply the outlined version of the badge. {{< preview id="outlined" lang="html" >}} {{< /preview >}} #### Colors {{< preview id="colors" lang="html" >}}
{{< /preview >}} ### Position The badge is available in different positions (by default the badge is displayed top right from the container). To change the badge position, use the `is-top-left`, `is-top`, `is-top-right`, `is-right`, `is-bottom-right`, `is-bottom`, `is-bottom-left` or `is-left` modifier on the `.badge` container: Tooltip position can be changed by adding one of the following classes to the HTML element containing the tooltip: `has-tooltip-right`, `has-tooltip-bottom`, `has-tooltip-left`. {{< preview id="position" lang="html" >}}
Badge top left Badge top center Badge top right Badge right Badge bottom right Badge bottom center Badge bottom left Badge left
{{< /preview >}}