Skip to content

Commit 9887836

Browse files
committed
upgrade
- update packages - fixed #10
1 parent f20d70b commit 9887836

File tree

18 files changed

+5339
-3848
lines changed

18 files changed

+5339
-3848
lines changed

.editorconfig

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

.eslintrc

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

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/react-prelodr.js
1+
dist
22
!modules
33
node_modules
44
bower_components

.travis.yml

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,29 +3,22 @@ sudo: false
33
language: node_js
44

55
node_js:
6-
- '4'
7-
- '5'
86
- '6'
97
- '7'
8+
- '8'
109

1110
git:
1211
depth: 1
1312

1413
branches:
1514
only:
1615
- master
17-
- /^greenkeeper-/
18-
- /^develop-/
19-
20-
notifications:
21-
email: false
16+
- /^greenkeeper/.*$/
2217

2318
cache:
19+
yarn: true
2420
directories:
2521
- node_modules
2622

27-
before_install:
28-
- npm install -g npm
29-
- npm --version
30-
31-
after_success: npm run coverage
23+
notifications:
24+
email: false
File renamed without changes.
File renamed without changes.

app/app.js

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
import React, { Component } from 'react'
2+
import ReactDOM from 'react-dom'
3+
import Prelodr from '../'
4+
5+
class App extends Component {
6+
onClick () {
7+
const pre = this.refs.myRef
8+
9+
pre
10+
.show('Starting...')
11+
.hide()
12+
.show('Processing...')
13+
.hide()
14+
.show('Finishig...')
15+
.hide()
16+
}
17+
18+
onShown () {
19+
console.log('When component is shown!')
20+
}
21+
22+
onHidden () {
23+
console.log('When component is hidden!')
24+
}
25+
26+
render () {
27+
return (
28+
<div>
29+
<button onClick={this.onClick.bind(this)}>Start</button>
30+
31+
<Prelodr
32+
ref='myRef'
33+
prefixClass='prelodr'
34+
duration={900}
35+
onShown={this.onShown}
36+
onHidden={this.onHidden}
37+
/>
38+
</div>
39+
)
40+
}
41+
}
42+
43+
ReactDOM.render(<App />, document.getElementById('root'))
File renamed without changes.

0 commit comments

Comments
 (0)