Coder Social home page Coder Social logo

brydzu / react-mdl Goto Github PK

View Code? Open in Web Editor NEW

This project forked from tleunen/react-mdl

0.0 2.0 0.0 8 MB

React Components for Material Design Lite

Home Page: https://tleunen.github.io/react-mdl/

License: MIT License

CSS 69.69% JavaScript 30.27% Shell 0.04%

react-mdl's Introduction

React-MDL

Maintenance Status NPM version Build Status Linux Coverage Status

Deprecation notice

This library is now deprecated. It's higly recommended to use Material Design Components instead.

Description

React-MDL is a set of React components build on top of Material Design Litev1.2.1

Requirements

Instead of using the official material.css and material.js files from the MDL project, you should use the files we provide in /extra. The reason to that is because the official Layout component is not fully compatible with React. We made a patch and we re-exported everything so people can still use it. If you're worried about the changes we made, you can take a look at the patch note or read about the issue in this ticket.

<link rel="stylesheet" href="material.css">
<script src="material.js"></script>
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">

Create React App

The above instructions won’t work if you use Create React App with react-scripts higher than 0.4.0.
If you use it, add only this one line to your HTML:

<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">

Then add these lines to src/index.js:

import 'react-mdl/extra/material.css';
import 'react-mdl/extra/material.js';

Installation

npm install --save react-mdl

Usage

You can use React-MDL through a bundler like webpack or browserify by importing react-mdl in your application:

import { Button, Card, CardText } from 'react-mdl';

// or...
import Button from 'react-mdl/lib/Button';
import { Card, CardText, CardActions } from 'react-mdl/lib/Card';

Alternatively, you can include node_modules/react-mdl/out/ReactMDL.js as a script, but you'll likely want to copy it to a folder outside of node_modules first, such as lib or vendor. Then a global ReactMDL will be available:

const { Button, Card, CardText } = ReactMDL;

For a listing of available components, as well as specific usage information, check out the Components page on the website.

Some extra components can be found in the react-mdl-extra package.

License

MIT, see LICENSE.md for details.

react-mdl's People

Contributors

1j01 avatar abrabah avatar adam187 avatar augustin82 avatar awjreynolds avatar carlbarrdahl avatar darkyen avatar dirtyhairy avatar download avatar drager avatar durandj avatar faergeek avatar gabrielbull avatar gaearon avatar greenkeeperio-bot avatar greggigon avatar hribb avatar janpieterz avatar jguffey avatar jlc467 avatar kradio3 avatar kuirak avatar pablocubico avatar permagate avatar peterssonjesper avatar sanyatuning avatar sarink avatar slybridges avatar tleunen avatar undeadlol1 avatar

Watchers

 avatar  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.