[React Lightning Components](https://react-lightning-components.firebaseapp.com/ ) are [react](http://facebook.github.io/react/) components that implement [Lightning Design System.](https://www.lightningdesignsystem.com/)
[![CircleCI](https://circleci.com/gh/reiniergs/react-lightning-components/tree/master.svg?style=svg)](https://circleci.com/gh/reiniergs/react-lightning-components/tree/master) [![Coverage Status](https://coveralls.io/repos/github/reiniergs/react-lightning-components/badge.svg?branch=master)](https://coveralls.io/github/reiniergs/react-lightning-components?branch=master) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)Installation
Lightning Design System is available as an npm package.
$ yarn add react-slds
##### or
$ npm install react-slds --save
Usage
Here is a quick example to get you started, it's all you need:
import React from 'react';
import ReactDOM from 'react-dom';
import Button from 'react-slds/components/button';
function App() {
return (
<Button
label="Hello World!"
variant="brand"
onClick={() => alert('Hello World!')}
/>
);
}
ReactDOM.render(
<App />,
document.getElementById('container')
);
Yes, it's really all you need to get started as you can see in this live and interactive demo:
Running locally
- git clone https://github.com/reiniergs/react-lightning-components.git
- cd react-lightning-components
- npm install
- npm start
- navigate to http://localhost:6060/