Skip to content

Commit 220395a

Browse files
committed
add github home page, switch to yarn
1 parent 9a46817 commit 220395a

File tree

6 files changed

+8791
-16
lines changed

6 files changed

+8791
-16
lines changed

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
npm-debug.log
88
yarn-error.log
99
node_modules
10-
package-lock.json
1110
lib
1211
dist
1312
.docz

.prettierrc

Lines changed: 0 additions & 11 deletions
This file was deleted.

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77
React tooltip component based on [react-popper](https://github.com/FezVrasta/react-popper), the
88
React wrapper around [popper.js](https://popper.js.org/) library.
99

10+
## Homepage
11+
https://mohsinulhaq.github.io/react-popper-tooltip
12+
1013
## Example
1114
https://codesandbox.io/s/pykkz77z5j
1215

@@ -15,6 +18,10 @@ https://codesandbox.io/s/pykkz77z5j
1518
```
1619
npm install react-popper-tooltip
1720
```
21+
or
22+
```
23+
yarn add react-popper-tooltip
24+
```
1825

1926
```jsx
2027
import React from 'react';
@@ -137,6 +144,11 @@ To fiddle with our example recipes, run:
137144
> npm install
138145
> npm run docs
139146
```
147+
or
148+
```
149+
> yarn
150+
> yarn docs
151+
```
140152
and open up [localhost:3000](http://localhost:3000) in your browser.
141153

142154
## Props

doczrc.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@ import { css } from 'docz-plugin-css';
33
export default {
44
title: 'react-popper-tooltip',
55
description: 'Documentation',
6+
base: '/react-popper-tooltip/',
67
plugins: [css()]
78
};

package.json

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "react-popper-tooltip",
33
"version": "2.3.4",
44
"description": "React tooltip library built around react-popper",
5-
"homepage": "https://github.com/mohsinulhaq/react-popper-tooltip",
5+
"homepage": "https://mohsinulhaq.github.io/react-popper-tooltip",
66
"repository": {
77
"type": "git",
88
"url": "https://github.com/mohsinulhaq/react-popper-tooltip"
@@ -16,12 +16,13 @@
1616
"typings/react-popper-tooltip.d.ts"
1717
],
1818
"scripts": {
19-
"build": "npm run build:cjs; npm run build:esm; mkdir -p dist && cp src/styles.css dist",
19+
"build": "yarn build:cjs; yarn build:esm; mkdir -p dist && cp src/styles.css dist",
2020
"build:cjs": "babel --delete-dir-on-start src -d lib/cjs",
2121
"build:esm": "babel --delete-dir-on-start --env-name esm src -d lib/esm",
22-
"prepare": "npm run build",
22+
"prepare": "yarn build && yarn docs:deploy",
2323
"docs": "docz dev",
24-
"docs:build": "docz build"
24+
"docs:build": "docz build",
25+
"docs:deploy": "yarn docs:build && cp .docz/dist/index.html .docz/dist/404.html && gh-pages -d .docz/dist"
2526
},
2627
"keywords": [
2728
"react",
@@ -36,6 +37,9 @@
3637
"browserslist": [
3738
"defaults"
3839
],
40+
"prettier": {
41+
"singleQuote": true
42+
},
3943
"peerDependencies": {
4044
"react": "^16.3.0",
4145
"react-dom": "^16.3.0"
@@ -53,6 +57,7 @@
5357
"@babel/preset-react": "^7.0.0",
5458
"docz": "^0.11.2",
5559
"docz-plugin-css": "^0.11.0",
60+
"gh-pages": "^2.0.0",
5661
"prop-types": "^15.6.2",
5762
"react": "^16.5.2",
5863
"react-dom": "^16.5.2"

0 commit comments

Comments
 (0)