https://github.com/timche/talk-prettier-and-friends
Slides and examples from my talk at HannoverJS in November 2017
https://github.com/timche/talk-prettier-and-friends
css husky javascript json less lint-staged markdown prettier react scss talk
Last synced: 7 months ago
JSON representation
Slides and examples from my talk at HannoverJS in November 2017
- Host: GitHub
- URL: https://github.com/timche/talk-prettier-and-friends
- Owner: timche
- License: mit
- Created: 2017-11-23T12:53:44.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2017-11-26T20:08:26.000Z (almost 8 years ago)
- Last Synced: 2025-01-25T16:30:03.685Z (9 months ago)
- Topics: css, husky, javascript, json, less, lint-staged, markdown, prettier, react, scss, talk
- Homepage:
- Size: 9.77 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Talk: Prettier and Friends
> Slides and examples from my talk at HannoverJS in November 2017
## Slides
http://slides.com/timche/formatting-code-with-prettier-and-friends
## VOD
[](https://www.youtube.com/watch?v=qOnTh7xwvpY)
## Examples Usage
This repository contains two branches `master` and `pre-commit-hook` demonstrating two ways of formatting files in a `examples` folder with [Prettier](https://prettier.io). Checkout `package.json` on both branches for more details.
### `master`
Running Prettier manually.
```sh
# Install dependencies
npm install# Run Prettier
npm run prettier
```### `pre-commit-hook`
Running [Prettier](https://github.com/prettier/prettier) as a [Git `pre-commit` hook](https://git-scm.com/book/gr/v2/Customizing-Git-Git-Hooks) with [Husky](https://github.com/typicode/husky) and [lint-staged](https://github.com/okonet/lint-staged).
```sh
# Instal dependencies
npm install# Add `examples/` from `master`
git checkout master examples# Commit
git commit -m 'add examples'
```