GithubHelp home page GithubHelp logo

p0nyong / react-foundation Goto Github PK

View Code? Open in Web Editor NEW

This project forked from digiaonline/react-foundation

0.0 1.0 0.0 487 KB

Foundation as React components.

Home Page: https://react.foundation

License: MIT License

JavaScript 100.00%

react-foundation's Introduction

React + Foundation

Build Status Test Coverage Maintainability StyleCI npm version npm downloads License

Foundation as React components.

Demo

https://react.foundation

Components with Bit

Motivation

Foundation is both feature-rich and easy to customize. React on the other hand is awesome because of its simplicity. It's even more awesome when combined with Redux and Immutable.

After building quite a few applications with React and Foundation we noticed that we were writing the same components over and over again. First we tried to find a library that would do the job, but there was none that met our needs. So we collected our notes, started coding and here's the result.

We hope you enjoy it as much as we do!

What's in the box?

The goal is to wrap every part of Foundation into re-usable React components following the framework's best practices. The primary focus is ease-of-use and extensibility. We use pure render components, also known as stateless components, whenever possible to keep the memory usage to a minimum. Stateful components are only used for larger components, such as ResponsiveNavigation, where state is actually necessary. All components are unit-tested to ensure their quality.

Here is a list of the available components:

More components coming soon!

Install

Install library:

npm install react-foundation --save

Install foundation-sites:

npm install foundation-sites --save

Usage

// Add Foundation to index.js
import 'foundation-sites/dist/css/foundation.min.css';

// import components
import { Button, Colors } from 'react-foundation';

// Use components ...
function SubmitButton() {
  return <Button color={Colors.SUCCESS}>Submit</Button>;
}

Documentation is at https://react.foundation and you can use our React Boilerplate as a reference.

Note: Newer versions of foundation-sites do not offer out of the box support for <Row/> and <Column/> components. If working with a newer version, <Grid/> and <Cell/> components should be used instead.

// Previous versions
<Row className="display">
  <Column small={2} large={4}>4 columns</Column>
  <Column small={4} large={4}>4 columns</Column>
  <Column small={6} large={4}>4 columns</Column>
</Row>

// Newer versions
<Grid className="display">
  <Cell small={2} large={4}>4 columns</Cell>
  <Cell small={4} large={4}>4 columns</Cell>
  <Cell small={6} large={4}>4 columns</Cell>
</Grid>

Contributing

Please read our guidelines.

Credits

  • Thanks to @jmreidy for releasing the react-foundation package name to us on NPM.

License

See LICENSE.

react-foundation's People

Contributors

crisu83 avatar hugovk avatar jalle19 avatar dependabot[bot] avatar victorstep avatar danielruf avatar vaaralav avatar bobwalker99 avatar imsnif avatar joshk2 avatar devrasec avatar edude03 avatar santtusulander avatar zoe-gonzales avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.