Skip to content

Commit 4aac756

Browse files
committed
Merge pull request #177 from bhamodi/master
File cleanup + lint fixes.
2 parents 6388603 + 54cecac commit 4aac756

24 files changed

+127
-129
lines changed

docs/sass/materialize.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,4 @@
3535
@import "components/slider";
3636
@import "components/date_picker/default.scss";
3737
@import "components/date_picker/default.date.scss";
38-
@import "components/date_picker/default.time.scss";
38+
@import "components/date_picker/default.time.scss";

examples/flux-chat/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ At this point defined how our application manages state over time by creating an
187187

188188
Getters can take 2 forms:
189189

190-
1. A KeyPath such as `['messages']` which equates to a `state.getIn(['messages'])` on the app state `Immutable.Map`.
190+
1. A KeyPath such as `['messages']` which equates to a `state.getIn(['messages'])` on the app state `Immutable.Map`.
191191
2. An array with the form `[ [keypath | getter], [keypath | getter], ..., tranformFunction]`
192192

193193
##### `modules/chat/getters.js`

examples/flux-chat/js/mock-data.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ module.exports = [
66
authorName: 'Bill',
77
text: 'Hey Jing, want to give a Flux talk at ForwardJS?',
88
isRead: false,
9-
timestamp: Date.now() - 99999
9+
timestamp: Date.now() - 99999,
1010
},
1111
{
1212
id: 'm_2',
@@ -15,7 +15,7 @@ module.exports = [
1515
authorName: 'Bill',
1616
text: 'Seems like a pretty cool conference.',
1717
isRead: false,
18-
timestamp: Date.now() - 89999
18+
timestamp: Date.now() - 89999,
1919
},
2020
{
2121
id: 'm_3',
@@ -24,7 +24,7 @@ module.exports = [
2424
authorName: 'Jing',
2525
text: 'Sounds good. Will they be serving dessert?',
2626
isRead: false,
27-
timestamp: Date.now() - 79999
27+
timestamp: Date.now() - 79999,
2828
},
2929
{
3030
id: 'm_4',
@@ -33,7 +33,7 @@ module.exports = [
3333
authorName: 'Bill',
3434
text: 'Hey Dave, want to get a beer after the conference?',
3535
isRead: false,
36-
timestamp: Date.now() - 69999
36+
timestamp: Date.now() - 69999,
3737
},
3838
{
3939
id: 'm_5',
@@ -42,7 +42,7 @@ module.exports = [
4242
authorName: 'Dave',
4343
text: 'Totally! Meet you at the hotel bar.',
4444
isRead: false,
45-
timestamp: Date.now() - 59999
45+
timestamp: Date.now() - 59999,
4646
},
4747
{
4848
id: 'm_6',
@@ -51,7 +51,7 @@ module.exports = [
5151
authorName: 'Bill',
5252
text: 'Hey Brian, are you going to be talking about functional stuff?',
5353
isRead: false,
54-
timestamp: Date.now() - 49999
54+
timestamp: Date.now() - 49999,
5555
},
5656
{
5757
id: 'm_7',
@@ -60,6 +60,6 @@ module.exports = [
6060
authorName: 'Brian',
6161
text: 'At ForwardJS? Yeah, of course. See you there!',
6262
isRead: false,
63-
timestamp: Date.now() - 39999
64-
}
63+
timestamp: Date.now() - 39999,
64+
},
6565
]

examples/flux-chat/js/modules/chat/actions.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@ exports.createMessage = function(text, threadID) {
2222
var id = 'm_' + timestamp
2323
var threadName = flux.evaluate([
2424
getters.threadsMap,
25-
threadsMap => threadsMap.getIn([threadID, 'threadName'])
25+
threadsMap => threadsMap.getIn([threadID, 'threadName']),
2626
])
2727
var authorName = 'Jordan'
2828

2929
flux.dispatch(actionTypes.ADD_MESSAGE, {
30-
message: { id, threadID, threadName, authorName, timestamp, text }
30+
message: { id, threadID, threadName, authorName, timestamp, text },
3131
})
3232
}
3333

examples/flux-chat/js/modules/chat/getters.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
// it is idiomatic to facade all data access through getters, that way a component only has to subscribe to a getter making it agnostic
2-
// to the underyling stores / data transformation that is taking place
2+
// to the underlying stores / data transformation that is taking place
33
exports.threadsMap = ['threads']
44

55
exports.threads = [
66
exports.threadsMap,
7-
threadsMap => threadsMap.toList()
7+
threadsMap => threadsMap.toList(),
88
]
99

1010
exports.currentThread = [
1111
['currentThreadID'],
1212
exports.threadsMap,
13-
(currentThreadID, threadsMap) => threadsMap.get(currentThreadID)
13+
(currentThreadID, threadsMap) => threadsMap.get(currentThreadID),
1414
]
1515

1616
exports.latestThread = [
@@ -21,13 +21,13 @@ exports.latestThread = [
2121
thread.get('messages').last().get('timestamp')
2222
})
2323
.last()
24-
}
24+
},
2525
]
2626

2727

2828
exports.currentThreadID = [
2929
exports.currentThread,
30-
thread => thread ? thread.get('threadID') : null
30+
thread => thread ? thread.get('threadID') : null,
3131
]
3232

3333
exports.unreadCount = [
@@ -39,5 +39,5 @@ exports.unreadCount = [
3939
}
4040
return accum
4141
}, 0)
42-
}
42+
},
4343
]

examples/flux-chat/js/modules/chat/stores/current-thread-id-store.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
var Nuclear = require('nuclear-js')
2-
var toImmutable = Nuclear.toImmutable
32
var actionTypes = require('../action-types')
43

54
module.exports = new Nuclear.Store({
@@ -11,7 +10,7 @@ module.exports = new Nuclear.Store({
1110
initialize() {
1211
// all action handlers are pure functions that take the current state and payload
1312
this.on(actionTypes.CLICK_THREAD, setCurrentThreadID)
14-
}
13+
},
1514
})
1615

1716
function setCurrentThreadID(state, { threadID }) {

examples/flux-chat/js/modules/chat/stores/thread-store.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ module.exports = new Nuclear.Store({
1313
// all action handlers are pure functions that take the current state and payload
1414
this.on(actionTypes.ADD_MESSAGE, addMessage)
1515
this.on(actionTypes.CLICK_THREAD, setMessagesRead)
16-
}
16+
},
1717
})
1818

1919
/**

examples/flux-chat/webpack.config.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@ module.exports = {
77

88
output: {
99
path: './',
10-
filename: "[name].js",
10+
filename: '[name].js',
1111
},
1212

1313
module: {
1414
loaders: [
1515
{ test: /\.js$/, exclude: /node_modules/, loader: 'babel-loader'},
1616
// required for react jsx
17-
{ test: /\.react.js$/, loader: "jsx-loader" },
18-
]
17+
{ test: /\.react.js$/, loader: 'jsx-loader' },
18+
],
1919
},
2020

2121
resolve: {

examples/rest-api/primer.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/rest-api/src/mock-server.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ var DATA = {
1616
name: 'jane',
1717
1818
},
19-
}
19+
},
2020
}
2121

2222
/**

0 commit comments

Comments
 (0)