material-design-lite/README.md

122 lines
6.1 KiB
Markdown
Raw Normal View History

# [![Web Starter Kit](https://cloud.githubusercontent.com/assets/170270/3343034/ceef6e92-f899-11e3-96b9-5d9d69d97a00.png)](https://github.com/google/web-starter-kit/releases)
2014-04-16 06:26:21 -07:00
2014-05-16 02:59:52 -07:00
## Overview
2014-04-16 07:12:57 -07:00
2014-06-19 09:28:42 -07:00
[Web Starter Kit](http://developers.google.com/web/starter-kit) is a starting point for multi-screen web development. It encompasses opinionated recommendations on boilerplate and tooling for building an experience that works great across multiple devices. We help you stay productive and aligned with the best practices outlined in Google's [Web Fundamentals](http://developers.google.com/web/fundamentals).
2014-04-16 07:12:57 -07:00
[![](https://cloud.githubusercontent.com/assets/170270/3343033/ceee251e-f899-11e3-9dd9-e313cf2522ec.png)](https://developers.google.com/web/starter-kit/ 'Features')
2014-05-24 07:48:00 -07:00
2014-05-23 12:02:58 -07:00
## Quickstart
[Download](https://github.com/google/web-starter-kit/releases) the kit or clone this repository and build on what we include in the `app` directory.
2014-06-19 05:54:24 -07:00
We provide 2 HTML starting points, from which you can choose:
2014-05-27 02:27:36 -07:00
- `index.html` - the default starting point, containing layout and a slide-out menu
2014-06-19 09:28:42 -07:00
- `basic.html` - includes no layout
2014-06-16 07:03:08 -07:00
2014-06-18 01:29:41 -07:00
## Tooling
2014-06-19 11:28:57 -07:00
If you would like to use the optional tooling we provide, make sure your system has [Node.js](http://nodejs.org), [Ruby](https://www.ruby-lang.org/), [gulp.js](http://gulpjs.com) and [Sass](http://sass-lang.com/install) installed.
2014-06-18 01:29:41 -07:00
2014-06-18 01:54:50 -07:00
### Node
2014-06-19 11:28:57 -07:00
Let's check to see if you already have Node installed. Bring up a terminal and type `node --version`. If Node responds, and if it shows a version at or above v0.10.x, proceed to checking if you have Ruby installed too. If you require Node, go to [nodejs.org](http://nodejs.org/) and click on the big green Install button.
2014-06-18 01:54:50 -07:00
2014-06-18 01:45:29 -07:00
### Ruby
2014-06-19 11:28:57 -07:00
Bring up a terminal and type `ruby --version`. If Ruby responds, and if it shows a version number at or above 1.8.7 then type `gem --version`. If you don't see any errors, proceed to installing the Sass gem. If you require Ruby, it can be installed from the [Ruby downloads](https://www.ruby-lang.org/en/downloads/) page.
2014-06-18 01:54:50 -07:00
2014-06-19 11:28:57 -07:00
### Sass
2014-06-19 11:28:57 -07:00
Bring up a terminal and type `sass --version`. If Sass is installed it should return a version number at or above 3.3.x. If you don't see any errors, proceed to the Gulp installation. If you need to install Sass, see the command-line instructions on the [Sass installation](http://sass-lang.com/install) page.
### Gulp
2014-06-18 01:45:29 -07:00
2014-06-19 11:28:57 -07:00
Bring up a terminal and type `gulp --version`. If Gulp is installed it should return a version number at or above 3.5.x. If you don't see any errors, proceed to the Gulp commands section. If you need to install Gulp, open up a terminal and type in the following:
2014-05-23 12:02:58 -07:00
```sh
$ npm install --global gulp
```
2014-06-18 02:48:28 -07:00
This will install Gulp globally. Depending on your user account, you may need to gain elevated permissions using `sudo` (i.e `sudo npm install --global gulp`). Next, install the local dependencies Web Starter Kit requires:
```sh
2014-06-16 07:03:08 -07:00
$ npm install
```
2014-05-23 12:02:58 -07:00
That's it! You should now have everything needed to use the Gulp tools in Web Starter Kit.
2014-06-19 05:50:10 -07:00
### Gulp Commands
You can now use Gulp with the following commands to stay productive during development:
2014-06-19 05:50:10 -07:00
#### Watch For Changes & Automatically Refresh Across Devices
```sh
$ gulp serve
2014-06-19 05:50:10 -07:00
```
2014-05-23 12:02:58 -07:00
2014-06-19 05:50:10 -07:00
This outputs an IP address you can use to locally test and another that can be used on devices connected to your network.
2014-06-16 07:03:08 -07:00
2014-06-19 05:50:10 -07:00
### Build & Optimize
```sh
2014-06-16 07:03:08 -07:00
$ gulp
2014-05-23 12:02:58 -07:00
```
2014-04-16 07:12:57 -07:00
2014-06-19 05:50:10 -07:00
Build and optimize the current project, ready for deployment. This includes linting as well as image, script, stylesheet and HTML optimization and minification.
#### Performance Insights
```sh
$ gulp pagespeed
```
Runs the deployed (public) version of your site against the [PageSpeed Insights](https://developers.google.com/speed/pagespeed/insights/) API to help you stay on top of where you can improve.
2014-06-16 03:05:24 -07:00
## Web Performance
2014-05-16 02:59:52 -07:00
2014-06-16 03:26:01 -07:00
Web Starter Kit strives to give you a high performance starting point out of the box and we actively work on delivering the best [PageSpeed Insights](https://developers.google.com/speed/pagespeed/insights/) score and frame-rate possible.
2014-06-19 09:28:42 -07:00
In terms of CSS, opting to just use the minimal layout (main.css, h5bp.css) weighs in at ~7KB before modifications are made. Opting to use the Style Guide styles (the default) will take this up to ~39KB. It is your choice which path makes the most sense for your project, however notes on excluding Style Guide styles are in our gulpfile.
2014-06-19 07:22:40 -07:00
2014-06-16 07:03:08 -07:00
## Browser Support
2014-06-16 03:26:01 -07:00
At present, we officially aim to support the following browsers:
* IE10, IE11, IE Mobile 10
2014-06-16 03:26:01 -07:00
* FF 30, 31
* Chrome 34, 35
* Safari 7, 8
* Opera 23, 24
* iOS Safari 7, 8
* Opera Coast
* Android / Chrome 4.4, 4.4.3
* BlackBerry 10
2014-06-16 03:26:01 -07:00
2014-06-16 07:03:08 -07:00
This is not to say that Web Starter Kit cannot be used in browsers older than those reflected, but merely that our focus will be on ensuring our layouts work great in the above.
2014-06-06 03:55:13 -07:00
2014-06-18 01:40:48 -07:00
## Troubleshooting
If you find yourself running into issues during installation or running the tools, please check our [Troubleshooting](https://github.com/google/web-starter-kit/wiki/Troubleshooting) guide and then open an [issue](https://github.com/google/web-starter-kit/issues). We would be happy to discuss how they can be solved.
2014-06-18 01:40:48 -07:00
2014-06-19 07:22:40 -07:00
## A Boilerplate-only Option
2014-06-19 06:18:32 -07:00
If you would prefer not to use any of our tooling, delete the following files from the project: `package.json`, `gulpfile.js`, `.jshintrc` and `.travis.yml`. You can now safely use the boilerplate with an alternative build-system or no build-system at all if you choose.
2014-06-19 06:18:32 -07:00
2014-06-06 03:55:13 -07:00
## Inspiration
2014-06-19 08:51:18 -07:00
Web Starter Kit is inspired by [Mobile HTML5 Boilerplate](http://html5boilerplate.com/mobile/) and Yeoman's [generator-gulp-webapp](https://github.com/yeoman/generator-gulp-webapp), having taken input from contributors to both projects during development. Our [FAQs](https://github.com/google/web-starter-kit/wiki/FAQ) attempt to answer commonly asked questions about the project.
2014-06-06 05:06:29 -07:00
2014-06-16 03:14:04 -07:00
## Contributing
Contributions, questions and comments are all welcome and encouraged. For code contributions to Web Starter Kit, please see our [Contribution guide](CONTRIBUTING.md) before submitting a pull request. [Website](https://developers.google.com/web/starter-kit/) related issues should be filed on the [Web Fundamentals](https://github.com/google/WebFundamentals/issues/new) issue tracker.
2014-06-16 03:14:04 -07:00
2014-06-06 05:06:29 -07:00
## License
2014-06-19 11:28:57 -07:00
Apache 2.0
2014-06-06 05:06:29 -07:00
Copyright 2014 Google Inc