Skip to content

Commit 2091d96

Browse files
committed
Merge pull request airbnb#36 from thisconnect/master
small code example and typo fixes
2 parents b74ba8b + c4ae7e7 commit 2091d96

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

README.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
1. [Constructors](#constructors)
2626
1. [Modules](#modules)
2727
1. [jQuery](#jquery)
28-
1. [ES5 Compatability](#es5)
28+
1. [ES5 Compatibility](#es5)
2929
1. [Testing](#testing)
3030
1. [Performance](#performance)
3131
1. [Resources](#resources)
@@ -87,14 +87,14 @@
8787
// bad
8888
var superman = {
8989
class: 'superhero',
90-
default: { clark: kent },
90+
default: { clark: 'kent' },
9191
private: true
9292
};
9393
9494
// good
9595
var superman = {
9696
klass: 'superhero',
97-
defaults: { clark: kent },
97+
defaults: { clark: 'kent' },
9898
hidden: true
9999
};
100100
```
@@ -132,7 +132,7 @@
132132
- If you don't know array length use Array#push.
133133

134134
```javascript
135-
var someStack = [],
135+
var someStack = [];
136136
137137
138138
// bad
@@ -173,10 +173,10 @@
173173
var name = 'Bob Parr';
174174
175175
// bad
176-
var fullName = "Bob" + this.lastName;
176+
var fullName = "Bob " + this.lastName;
177177
178178
// good
179-
var fullName = 'Bob' + this.lastName;
179+
var fullName = 'Bob ' + this.lastName;
180180
```
181181

182182
- Strings longer than 80 characters should be written across multiple lines using string concatenation.
@@ -1182,7 +1182,7 @@
11821182
var previousFancyInput = global.FancyInput;
11831183
11841184
function FancyInput(options) {
1185-
options || (options = {});
1185+
this.options = options || {};
11861186
}
11871187
11881188
FancyInput.noConflict = function noConflict() {
@@ -1261,7 +1261,7 @@
12611261
**[[⬆]](#TOC)**
12621262

12631263

1264-
## <a name='es5'>ECMAScript 5 Compatability</a>
1264+
## <a name='es5'>ECMAScript 5 Compatibility</a>
12651265

12661266
- Refer to [Kangax](https://twitter.com/kangax/)'s ES5 [compatibility table](http://kangax.github.com/es5-compat-table/)
12671267

@@ -1323,7 +1323,7 @@
13231323

13241324
**Blogs**
13251325

1326-
- [DailyJS](//dailyjs.com)
1326+
- [DailyJS](http://dailyjs.com/)
13271327
- [JavaScript Weekly](http://javascriptweekly.com/)
13281328
- [JavaScript, JavaScript...](http://javascriptweblog.wordpress.com/)
13291329
- [Bocoup Weblog](http://weblog.bocoup.com/)

0 commit comments

Comments
 (0)