mirror of
https://github.com/kevinsqi/react-circular-progressbar.git
synced 2026-01-18 15:55:06 +00:00
move build => dist, include styles.css in dist
This commit is contained in:
parent
42ad725fab
commit
8a5a31de15
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,7 +1,6 @@
|
||||
node_modules
|
||||
npm-debug.log
|
||||
.DS_Store
|
||||
build
|
||||
.cache
|
||||
*.iml
|
||||
.idea
|
||||
|
||||
@ -15,14 +15,16 @@ Install the npm module:
|
||||
npm install react-circular-progressbar
|
||||
```
|
||||
|
||||
**Important**: you'll also need to copy [src/styles.css](src/styles.css) into your repo to use the default styling!
|
||||
|
||||
## Usage
|
||||
|
||||
Import the component:
|
||||
|
||||
```javascript
|
||||
import CircularProgressbar from 'react-circular-progressbar';
|
||||
|
||||
// If you have a CSS loader configured, you can import the stylesheet.
|
||||
// Otherwise, you can copy this CSS file into your project.
|
||||
import 'react-circular-progressbar/dist/styles.css';
|
||||
```
|
||||
|
||||
..and use the component in your JSX:
|
||||
@ -52,7 +54,7 @@ For more in-depth examples, take a look at the [demo code](docs/demo.jsx) to see
|
||||
|
||||
## Customizing styles
|
||||
|
||||
Use plain CSS to customize the styling - the [default CSS](src/styles.css) is a good starting point, but you can modify it as needed.
|
||||
Use plain CSS to customize the styling - the default CSS is a good starting point, but you can override it as needed.
|
||||
|
||||
#### CSS hooks
|
||||
|
||||
|
||||
0
src/styles.css → dist/styles.css
vendored
0
src/styles.css → dist/styles.css
vendored
@ -3,7 +3,7 @@
|
||||
"version": "0.7.0",
|
||||
"description": "A circular progress indicator component",
|
||||
"author": "Kevin Qi <iqnivek@gmail.com>",
|
||||
"main": "./build/index.js",
|
||||
"main": "./dist/index.js",
|
||||
"repository": "https://github.com/iqnivek/react-circular-progressbar.git",
|
||||
"license": "MIT",
|
||||
"keywords": [
|
||||
@ -12,9 +12,13 @@
|
||||
"react-component",
|
||||
"svg"
|
||||
],
|
||||
"style": "dist/styles.css",
|
||||
"files": {
|
||||
"dist"
|
||||
},
|
||||
"scripts": {
|
||||
"build": "NODE_ENV=production webpack && npm run build:demo",
|
||||
"build:demo": "NODE_ENV=demo webpack && cp ./src/styles.css ./docs/styles.css",
|
||||
"build:demo": "NODE_ENV=demo webpack && cp ./dist/styles.css ./docs/styles.css",
|
||||
"clean": "rimraf build",
|
||||
"lint": "eslint src test",
|
||||
"prepare": "npm run clean && npm run build",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user