5 CSS Frameworks For Your Next Project

What CSS Frameworks do you use? A framework like Bootstrap can be customize to suit your needs. Sometimes you have override the standard styles to get the design to work. You may want to use a framework that is flexible and doesn’t make design decisions for you. Here are 5 frameworks that you can use in your next project.

5 CSS Frameworks For Your Next Project
Photo by Shopify Partners from Burst

Pure CSS

Pure.css is small, responsive CSS framework. It allows you to easily create your own styles while providing responsive layout and common UI components. Pure.css is flexible that you can use it with other frameworks like Bootstrap without any issues. Monty Shokeen explains how you can start using [this framework] (https://www.sitepoint.com/introducing-pure-css-lightweight-responsive-framework/) in your next project.

Mini CSS

Mini.css is a minimal and responsive framework. You can quickly change the CSS file to make a custom design. It relies on CSS for the styling, so it won’t conflict with any JavaScript library that you need to use.

Bulma

Bulma is a CSS framework that is based on Flexbox. It is responsive, modular and free. Bulma is easy to learn and customize. You don’t need JavaScript to get started using this framework.

Tailwind CSS

Tailwind CSS is a different from other CSS frameworks. It provides utility classes that make it easy to rapidly build custom user interfaces. Tailwind doesn’t make design decisions for you. You can create a completely custom design without having to overriding a bunch of pre-built classes.

Materialize CSS

Materialize is a modern, responsive framework based on Material Design. You can choose to use the standard version with CSS and JavaScript or the SCSS version. With the Standard version, you can get started right away. The SCSS requires a Sass compiler.

When choosing a framework for your next project, you may want a small and minimal one or something that works with your existing styles. These 5 provide you with different options to help create a custom user experience.

5 Ways to Organize Your CSS

How do you write and organize your CSS? Do you prefer to use a structured method or not? With CSS, you can choose to use an existing method or develop your own. Some CMSes like WordPress have their own styles. When you use them, you need to follow their rules and guidelines.

5 Ways to Organize Your CSS
Photo by Photo Mix from Pixabay

Your styles can get big, messy and convoluted over time. It can be hard to maintain. You don’t know what you can delete or change because you aren’t sure what problems it will cause. Without a method for organizing, it may get harder and harder to keep things straight. You can choose to use BEM, OOCSS, SMACSS, Atomic CSS or build your own.

BEM

BEM is a way of writing CSS created by Yandex. It is a very structured style of writing CSS. BEM has a component-based approach. This approach divides the user interface into separate components. BEM uses the structure of Block, Element and Modifier. It makes development easy and fast to update.

OOCSS

OOCSS (object-oriented CSS) applies principles of object-oriented languages to help you write CSS. It encourages code reuse and makes it easier to maintain. OOCSS uses the object-oriented principle of abstraction to make the code reusable. It helps you to separate visual elements like color, fonts and borders from the content. This separation makes your code easier to update. Especially when you need to change colors, fonts or other branding-related items.

SMACSS

SMACSS is more of a style guide than a CSS architecture. Scalable and Modular Architecture for CSS provides guidelines for writing CSS. This style guide helps you build CSS that is flexible and maintainable. With SMACSS, you create your own rules for writing CSS.

Atomic CSS

Atomic CSS focuses on small, single-purposed classes. You build well-structured HTML templates, so that your changes doesn’t break your design.

Your Own Style

When you build a website on your own or part of a small team, you can choose how you write your CSS. You may combine methods to help solve certain design problems.

How do you choose a method?

It depends. When you are working on your own project, you can choose which one you want to use. When you are working on a project that uses a CSS framework, it may be easier to use the method that the framework uses.

The best way to learn which one you like is to read the documentation and build a project with it. Then, you’ll know when to use these methods.

3 Dashboard Design Inspirations on CodePen

An easy to read dashboard has from 5-9 pieces of information on it. By combining color, fonts and icons, you can make a dashboard simple and easy to use. I found these three examples on CodePen that you can use to inspire your own designs.

3 Dashboard Designs CodePen
Photo by Lukas from Pexels

Bootstrap 4 Dashboard Stats Example

It shows 6 different statistics using Bootstrap 4. Each statistics is in a separate box that was built using the card layout. @elmorabityounes uses the default classes from Bootstrap to color the background, border and text. The text formatting is kept simple by using header tags to display the copy. Each box has its own icon from Font Awesome. The result is a simple design with no additional CSS or JavaScript.

Bootstrap Dashboard Indicators

When you design a dashboard, you’ll need to use different type of indictors to display information. Herman Starikov shows you how to use Bootstrap to create different indicators. He combines Font Awesome, Flexbox and CSS Animation. Herman also uses icons as decorative background elements. With CSS and Animation, your dashboard doesn’t have to be plain or boring.

Full Dashboard Design

CodePen Admin Dashboard

This complete Dashboard has a statistics, charts, a map and a chat box. Haidarali Nadi Shah demonstrates how to use Flat design, Font Awesome and JavaScript for functionality and additional theming. It includes a side menu bar that shrinks and expands when you click on it.

With the above examples, you can include different pieces of information in your design. You can choose to HTML and CSS, a CSS Framework like Bootstrap or include JavaScript to create more complex functionality. No matter what methods you choose, you can create a dashboard that provides your customers with the information that they need. Before you design your next dashboard, remember to review these 3 Dashboard Design Tips.

Learning JSON

JSON stands for JavaScript Object Notation, which is a format for sharing data. As the name suggests, JSON is derived from JavaScript. Other languages like PHP, Python, Java, C# and Ruby can use it.

Learning JSON
Photo By: Image by xresch on Pixabay

Why use it?

JSON is readable and light weight. It requires less formatting than XML. JSON’s structure is a key-value pair format that is rendered in curly braces. You can choose to use it in a file (*.json), a string or as an object.

How do I create a JSON object?

  • Use curly braces to define the beginning and ending of the object
  • Put data in key/value pairs
  • Use a colon to separate the key from the value
  • Keys are strings
  • Values can numbers, strings, objects, arrays, booleans or null
  • Use a comma to separate each key/value pair

{
	"name" :  "Isaac",
	"age" : 50,
	"job" : "writer",
	"car" : null
}

Build a simple website with JSON

The key/value pair makes it easy to share data in web applications. You’ll need a language like JavaScript to display the data. The Mozilla Developer Network walks you through a simple example in their tutorial using JSON on a website. You build a one page website that lists 3 superheroes.

Modifying the website

The superhero website is a bit plain without images. I downloaded three images from Pixabay and updated the superhero.json file. I added a key/value pair for each image like “imageUrl”: “images/molecule-man.png”. Then, I modified the JavaScript to display the image.

I tweaked the CSS to put a border on each superhero member to make it look a little more card-like.

Screenshot of JSON Superhero Website

Where can I learn more?

Variable Fonts on the Web

Variable fonts is an OpenType font specification that puts different variations of a typeface into one single file instead of multiple font files for every variation that you may need. With a standard font, your visitors have to download multiple files which leads to more HTTP requests and data to their browsers. With a variable font, the file size may be about the same but you’ll have access to a much wider range of styles than currently available. For example, a font like Roboto has twelve font files which includes twelve variants. The variable font has one file and unlimited variants.

Variable Fonts on the Web
Photo By: Maret Hosemann

Can I Use It?

Not all browsers and operating systems support variable fonts. For example, Linux OSes need to download the latest Linux Freetype version and Macs need to use a Mac High Sierra (10.14) and Mojave.

For non-supporting browsers, you can use CSS Feature Queries to determine if it should load a standard font instead.

Why use Variable Fonts?

You can use a single font file that provides you with a wide range of widths, weights, slants and more. With less font files to download, your visitors don’t have as much to download. With a variable font, you have greater flexibility on how your text displays. You can use a wider variety of font variants to create certain affects that help define your style and voice. With most major browsers supporting this font type, you can start to use them in your next project.

Where can I see Variable Fonts in action?

You can try them out on v-fonts and Axis-Praxis.

Where can I learn more?