2016-09-11 11:00:49 +00:00
---
2018-04-09 16:32:12 +00:00
title: Getting started with Bulma
2016-09-11 11:00:49 +00:00
layout: documentation
doc-tab: overview
doc-subtab: start
2018-04-09 16:32:12 +00:00
breadcrumb:
- home
- documentation
- overview
- overview-start
2016-09-11 11:00:49 +00:00
---
2018-04-09 16:32:12 +00:00
< div class = "content" >
< p >
2021-01-27 23:30:42 +00:00
Bulma is a < strong > CSS library< / strong > . This means it provides CSS classes to help you style your HTML code.
< br >
To use Bulma, you can either use the pre-compiled < code > .css< / code > file or install the < code > .sass< / code > files so you can customize it to your needs.
2018-04-09 16:32:12 +00:00
< / p >
< / div >
2021-01-27 23:30:42 +00:00
< div class = "bd-options" >
< div class = "bd-option" >
< div class = "block media is-align-items-center" >
< div class = "media-left" >
< span class = "icon is-flex is-large has-text-link" >
< i class = "fab fa-css3 fa-2x" > < / i >
< / span >
< / div >
2017-11-05 19:35:23 +00:00
2021-01-27 23:30:42 +00:00
< div class = "media-content" >
< p class = "title is-4" > Get the Bulma < strong class = "has-text-link" > CSS< / strong > file< / p >
< p class = "subtitle" > A single < code > .css< / code > file that includes all of Bulma< / p >
< / div >
< / div >
2017-11-05 19:35:23 +00:00
2021-01-27 23:30:42 +00:00
< div class = "bd-option-item" >
< p class = "bd-option-title block has-text-grey-light is-size-5" >
< span class = "button bd-fat-button is-success is-light is-pulled-right" > Recommended< / span >
Option 1. < strong > Use a CDN< / strong >
< / p >
< p class = "block" >
You can import the CSS file directly from < a href = "{{ site.data.meta.jsdelivr }}" target = "_blank" > jsDelivr< / a > :
< / p >
{% capture jsdelivr_a %}
{% highlight css %}@import "https://cdn.jsdelivr.net/npm/bulma@{{ site.data.meta.version }}/css/bulma.min.css"{% endhighlight %}
{% endcapture %}
{% capture jsdelivr_b %}
{% highlight html %}< link rel = "stylesheet" href = "https://cdn.jsdelivr.net/npm/bulma@{{ site.data.meta.version }}/css/bulma.min.css" > {% endhighlight %}
{% endcapture %}
{%
include components/tabs.html
button_a="CSS @import"
button_b="HTML < link > "
item_a=jsdelivr_a
item_b=jsdelivr_b
%}
< p class = "block" >
The < strong > RTL version< / strong > is also available:
< / p >
{% capture jsdelivr_rtl_a %}
{% highlight css %}@import "https://cdn.jsdelivr.net/npm/bulma@{{ site.data.meta.version }}/css/bulma-rtl.min.css"{% endhighlight %}
{% endcapture %}
{% capture jsdelivr_rtl_b %}
{% highlight html %}< link rel = "stylesheet" href = "https://cdn.jsdelivr.net/npm/bulma@{{ site.data.meta.version }}/css/bulma-rtl.min.css" > {% endhighlight %}
{% endcapture %}
{%
include components/tabs.html
button_a="CSS @import"
button_b="HTML < link > "
item_a=jsdelivr_rtl_a
item_b=jsdelivr_rtl_b
%}
< p class = "block" >
Bulma is also available via < a href = "{{ site.data.meta.cdnjs }}" target = "_blank" > cdnjs< / a > .
< / p >
< / div >
< div class = "bd-option-item" >
< p class = "bd-option-title block has-text-grey-light is-size-5" >
Option 2. < strong > Download the Github release< / strong >
< / p >
< div class = "block" >
You can get the latest Bulma release as a < code > .zip< / code > from GitHub:
< / div >
< a class = "button bd-fat-button is-primary is-light" href = "{{ site.data.meta.download }}" >
Download v{{ site.data.meta.version }}
< / a >
< / div >
2018-04-09 16:32:12 +00:00
< / div >
2021-01-27 23:30:42 +00:00
< div class = "bd-option-or" >
< p > Or< / p >
2018-04-09 16:32:12 +00:00
< / div >
2017-11-05 19:35:23 +00:00
2021-01-27 23:30:42 +00:00
< div class = "bd-option" >
< div class = "block media is-align-items-center" >
< div class = "media-left" >
< span class = "icon is-flex is-large has-text-sass" >
< i class = "fab fa-sass fa-2x" > < / i >
< / span >
< / div >
2017-07-29 14:47:33 +00:00
2021-01-27 23:30:42 +00:00
< div class = "media-content" >
< p class = "title is-4" > Get the Bulma < strong class = "has-text-sass" > Sass< / strong > library< / p >
< p class = "subtitle" > A collection of < code > .sass< / code > files to build your own version of Bulma< / p >
< / div >
< / div >
< div class = "bd-option-item" >
< p class = "bd-option-title block has-text-grey-light is-size-5" >
< span class = "button bd-fat-button is-success is-light is-pulled-right" > Recommended< / span >
Option 1. < strong > Install the NPM package< / strong >
< / p >
< p class = "block" >
Bulma is available through < a href = "{{ site.data.meta.npm }}" target = "_blank" > npm< / a > :
< / p >
{% capture npm_item %}
{% highlight bash %}npm install bulma{% endhighlight %}
{% endcapture %}
{% capture yarn_item %}
{% highlight bash %}yarn install bulma{% endhighlight %}
{% endcapture %}
{%
include components/tabs.html
button_a="npm"
button_b="yarn"
item_a=npm_item
item_b=yarn_item
%}
< p class = "block" >
Bulma is also available via < a href = "{{ site.data.meta.cdnjs }}" target = "_blank" > cdnjs< / a > .
< / p >
< / div >
< div class = "bd-option-item" >
< p class = "bd-option-title block has-text-grey-light is-size-5" >
Option 2. < strong > Clone the GitHub repository< / strong >
< / p >
< p class = "block" >
Bulma is available on < a href = "{{ site.data.meta.github }}" target = "_blank" > GitHub< / a > :
< / p >
{% capture git_ssh %}
{% highlight bash %}{{ site.data.meta.git_ssh }}{% endhighlight %}
{% endcapture %}
{% capture git_https %}
{% highlight bash %}{{ site.data.meta.git_https }}{% endhighlight %}
{% endcapture %}
{% capture git_cli %}
{% highlight bash %}{{ site.data.meta.git_cli }}{% endhighlight %}
{% endcapture %}
{%
include components/tabs.html
button_a="SSH"
button_b="HTTPS"
button_c="GitHub CLI"
item_a=git_ssh
item_b=git_https
item_c=git_cli
%}
< div class = "message is-warning" >
< div class = "message-body" >
Note that the GitHub repository also includes this documentation, so it’ s significantly bigger than the NPM package.
< / div >
< / div >
< / div >
2018-04-09 16:32:12 +00:00
< / div >
< / div >
2017-07-29 14:47:33 +00:00
2018-04-09 21:25:26 +00:00
{% include elements/anchor.html name="Code requirements" %}
2017-07-29 14:47:33 +00:00
2018-04-09 16:32:12 +00:00
< div class = "content" >
< p >
For Bulma to work correctly, you need to make your webpage < strong > responsive< / strong > .
< / p >
< / div >
2018-01-18 15:43:10 +00:00
2018-04-09 16:32:12 +00:00
< article class = "media is-large" >
< div class = "media-left" >
< p class = "title is-5" > 1< / p >
< / div >
< div class = "media-content" >
< p class = "title is-5" >
Use the < strong > HTML5 doctype< / strong >
< / p >
{% highlight html %}<!DOCTYPE html> {% endhighlight %}
< / div >
< / article >
2018-01-18 15:43:10 +00:00
2018-04-09 16:32:12 +00:00
< article class = "media is-large" >
< div class = "media-left" >
< p class = "title is-5" > 2< / p >
< / div >
< div class = "media-content" >
< p class = "title is-5" >
Add the responsive < strong > viewport< / strong > meta tag
< / p >
{% highlight html %}< meta name = "viewport" content = "width=device-width, initial-scale=1" > {% endhighlight %}
2016-09-11 11:00:49 +00:00
< / div >
2018-04-09 16:32:12 +00:00
< / article >
2018-04-09 21:25:26 +00:00
{% include elements/anchor.html name="Starter template" %}
2018-04-09 16:32:12 +00:00
< div class = "content" >
< p >
If you want to get started < strong > right away< / strong > , you can use this < strong > HTML starter template< / strong > . Just copy/paste this code in a file and save it on your computer.
< / p >
< / div >
2021-01-27 23:30:42 +00:00
< div class = "bd-example bd-highlight-full" >
2018-04-09 21:25:26 +00:00
{% highlight html %}{% include snippets/getting-started.html %}{% endhighlight %}
2018-04-09 16:32:12 +00:00
< / div >
2018-04-09 21:25:26 +00:00
{% include elements/anchor.html name="bulma-start" %}
2018-04-09 16:32:12 +00:00
< div class = "content" >
< p >
2018-10-12 10:23:32 +00:00
< code > < a href = "{{ site.url }}/bulma-start/" > bulma-start< / a > < / code > is a tiny npm package that includes the < code > npm< / code > dependencies you need to build your own website with Bulma.
2018-04-09 16:32:12 +00:00
< / p >
< p >
2018-10-12 10:23:32 +00:00
< a class = "button is-link" href = "{{ site.url }}/bulma-start/" > Check it out< / a >
2018-04-09 16:32:12 +00:00
< / p >
< / div >