--- template: simple.tpl name: Introduction ---
Our pattern library comes as a easily distributed package, ready to use in multiple programming environments. It contains our basic CSS components and correct usage, as well as JavaScript components that are widely used across the website.
View on githubuStyle was initially created as a gem. Some of the Sass functions rely on Ruby to run. You can install it via any Gemfile and it will install the required dependencies.
gem 'ustyle', git: "git@github.com:uswitch/ustyle.git"
Install is as a bower package. This will pull down the original .scss
files and compiled static CSS + JS.
"dependencies": {
"ustyle": "git@github.com:uswitch/ustyle.git#~0.19.1"
}
Every time uStyle gets a new version, the version gets updated across our Cloudfront distributions.
<!-- get latest -->
<link href='//assets0.uswitch.com/s3/uswitch-assets-eu/ustyle/ustyle-latest.css' media='all' rel='stylesheet' type='text/css' />
<!-- get versioned -->
<link href='//assets0.uswitch.com/s3/uswitch-assets-eu/ustyle/VERSION/ustyle-latest.css' media='all' rel='stylesheet' type='text/css' />
"devDependencies": {
"ustyle": "git@github.com:uswitch/ustyle.git#~0.19.1"
}
We use Autoprefixer + Browserlist to decide what vendor prefixes to apply to our Sass
files. We have a slightly wider browser support than the default (here). Currently we support all the way to IE8.
Below is what we support. Each line is the minimum version or % use based on CanIUse metrics
Browser | Minimum version supported |
---|---|
Safari, Chrome | Last 5 versions |
Firefox | 22 |
Opera | 12.1 |
Internet Explorer | 8 (unless stated) |
Global usage | > 1% |
See our github for documentation on installing this across applications.