Skip to content
This repository has been archived by the owner on Jul 10, 2023. It is now read-only.

craigplummer/office-ui-fabric-js-rails

Repository files navigation

office-ui-fabric-core-rails

Gem Version

office-ui-fabric-rails integrates the Office UI Fabric JS framework from Microsoft into the Rails Asset Pipeline

Installation

Add this line to your application's Gemfile:

gem 'office-ui-fabric-js-rails'

And then execute:

bundle

Usage

Add Office UI Fabric to your CSS

CSS

Add the following line to the end of your app/assets/stylesheets/application.css file:

*= require fabric

If you also wish to use the Fabric components then you should also add

*= require fabric.components

Sass

If you are using Sass then you can add the following to your application.scss instead:

@import "Fabric";

If you also wish to use the Fabric components then you should also add

@import "Fabric.Components";

Or you can just import the components you wish to use from the components directory. The names match those listed on the fabric site. E.g to include the Breadcrumb component add

@import "components/Breadcrumb"

Add Office UI Fabric to your JS

Add the following to your app/assets/javascripts/application.js file:

//= require fabric

For information on how to use the Office UI Fabric framework see the documentation

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/craigplummer/office-ui-fabric-js-rails.

For issues with Office UI Fabric itself please use https://github.com/OfficeDev/Office-UI-Fabric

License

The Office UI Fabric framework and the rest of the office-ui-fabric-js-rails project are licenced under the MIT License