• This repository has been archived on 04/Nov/2020
  • Stars
    star
    244
  • Rank 165,885 (Top 4 %)
  • Language
    CSS
  • License
    MIT License
  • Created over 10 years ago
  • Updated over 7 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Flint is a powerful Sass grid framework designed for rapid responsive development.

Gem Bower NPM Travis GitHub license

What is Flint?

Flint is a responsive grid framework written in Sass, created to allow developers to rapidly produce responsive layouts that are built on a sophisticated foundation.

What sets Flint apart?

Most notably? The syntax. Being a designer myself, a large amount of time was spent on this aspect. Flint is very unique in the fact that it uses only a single mixin for all output: _(...).

Yes, it really is just an underscore. Easy to remember, huh? It shoves the function mumbo-jumbo out of the way and allows you to focus on the aspect that matters most: the actual layout. It also allows you to type your intentions in human terms.

@include _(from tablet to desktop) { ... }
@include _(16 12 8 4, $gutter: no-left);

In addition to that, as you can tell from the snippet above, Flint also handles your breakpoints for you. Long gone are the days that you need to download a separate plugin just so that you're able to create a truly responsive layout.

Flint allows you create an unlimited number of breakpoints, all of which have their own alias, column count and breakpoint. Want to name your 10 breakpoints after James Bond villians? By all means, go ahead.

One more cool thing? Flint is the only self-aware Sass grid system on the planet.* What does that mean? It means that every instance of Flint is logged into an 'instance map', so child elements can know their parent element's width; meaning we can have perfectly consistent gutters, no matter how odd your layout may be. Think of it as a self-correcting grid.

Check out this short introduction over at Sitepoint.com, and take it for a spin on SassMeister.com!

Enjoy.

Requirements

  • Sass ~> 3.4.0

Installation

  1. Install via Ruby gem install flint-gs, or Bower bower install flint --save-dev
  2. If you're using Compass, add require "flint" to your config.rb
  3. Import it into your stylesheet with @import "flint"

If you're not using Compass, you can require Flint and compile via cli:

scss --require ./lib/flint.rb example.scss > example.css

Documentation

Documentation is located here.

Tip: For simple projects, disable instance-maps, as it is has a large overhead and will increase your compile times.

Syntax support

As of 1.6.0, you can add syntax support for your preferred syntax. I built the system for BEM, but it should be easily extendable to support your preferred syntax. Simply create a function which parses a string of selectors into a valid list. For example, the BEM syntax function parses the selector string (for example, .block__element__element) like so,

///
/// Parser to support BEM syntax
///
/// @access private
///
/// @param {List} $selectors - string of selectors to parse
///
/// @return {List} - parsed list of selectors according to syntax
///
/// @group Internal Functions
///
@function flint-support-syntax-bem($selectors) { ... }

View Source

This will be parsed into a list of selectors: .block, .block__element, .block__element__element. The list of selectors can then be used by the instance system to look up a selectors parent, etc. To support your own preferred syntax: create a flint-support-syntax-<syntax-name> function and hook into it through the config "support-syntax": "<syntax-name>" option -- the system will attempt to use the call() function in order to parse the selector string.

Officially supported syntaxes

If you use one that isn't here, let me know and I'll look into officially supporting it.

Support

You can tweet @FlintGrid with any questions or issues and I'll look into it. Be sure to include a Gist or a SassMeister link.

Authors

Ezekiel Gabrielse

Contributing

As an open-source project, contributions are more than welcome, they're extremely helpful and actively encouraged. If you see any room for improvement, open an issue or submit a pull request. Also, make sure to take a look at the contributing doc.

License

Flint is available under the MIT license.

* According to Wikipedia, not really. But, all jokes aside, it's pretty awesome.

More Repositories

1

git-hound

Git plugin that prevents sensitive data from being committed.
Go
309
star
2

xo

Command line utility that composes regular expression matches.
Go
184
star
3

example-rails-webhook-system

An example of building a webhook system with Rails and Sidekiq
Ruby
30
star
4

example-rails-api-key-authentication

Example of implementing API key authentication in Ruby on Rails without Devise
Ruby
28
star
5

sass-prof

A code profiler for Sass libraries
Ruby
25
star
6

sympm

sympm allows you to run npm install from inside of a Vagrant virtual machine without hitting symlink issues
JavaScript
16
star
7

sitepoint-programmatically-insert-wp-posts

PHP
14
star
8

graphite

Graphite imports a folder of fonts and automagically outputs their font-face directives for you.
Ruby
13
star
9

sassy-export

Sassy Export is a lightweight Compass extension that allows you to export an encoded Sass map into an external JSON file.
Ruby
10
star
10

chrome-new-tab-vocab

Google Chrome extension that shows you a new word definition every time you open a new tab.
HTML
9
star
11

chrome-github-auto-tab-indent

Google Chrome extension that automatically adjusts tab indentation on GitHub (and Bitbucket!)
JavaScript
6
star
12

example-rails-totp-2fa

An example of implementing TOTP 2FA in a Ruby on Rails app using the ROTP gem.
Ruby
5
star
13

download-in-browser

JavaScript
5
star
14

guard-mthaml

Guard::MtHaml automatically compiles your MtHaml template files to PHP, Twig or static HTML.
PHP
3
star
15

channy

channy is a synchronous channel-like observer that allows easy orchestration of events
CoffeeScript
2
star
16

sitepoint-theme-juice

1
star
17

theme-juice-functions

Theme Juice helper-functions library.
PHP
1
star
18

theme-juice-vm

Deprecated in favor of our new virtual machine:
Shell
1
star