Skip to content

Commit df7fb5b

Browse files
committed
#75 commonJS support. Bump version to 4.2.2
1 parent c211663 commit df7fb5b

8 files changed

Lines changed: 58 additions & 48 deletions

File tree

LICENSE-MIT

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License (MIT)
22

3-
Copyright (c) 2010-2014 Dmitrii Pakhtinov
3+
Copyright (c) 2010-2015 Dmitrii Pakhtinov
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
66

bower.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "history",
33
"repo": "devote/HTML5-History-API",
44
"description": "HTML5 History API expansion for browsers not supporting pushState, replaceState",
5-
"version": "4.2.1",
5+
"version": "4.2.2",
66
"keywords": ["history", "pushState", "replaceState"],
77
"main": "history.js",
88
"scripts": ["history.js"],

component.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "html5-history-api",
3-
"version": "4.2.1",
3+
"version": "4.2.2",
44
"description": "HTML5 History API expansion for browsers not supporting pushState, replaceState",
55
"main": "history.js",
66
"scripts": ["history.js"],

history.ielte7.js

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* History API JavaScript Library v4.2.1
2+
* History API JavaScript Library v4.2.2
33
*
44
* Support: IE6+, FF3+, Opera 9+, Safari, Chrome and other
55
*
@@ -11,7 +11,7 @@
1111
* http://www.opensource.org/licenses/mit-license.php
1212
* http://www.gnu.org/licenses/gpl.html
1313
*
14-
* Update: 2015-05-22 13:02
14+
* Update: 2015-06-26 23:22
1515
*/
1616
(function(factory) {
1717
if (typeof define === 'function' && define['amd']) {
@@ -28,8 +28,13 @@
2828
};
2929
define([], factory);
3030
}
31-
// execute anyway
32-
factory();
31+
// commonJS support
32+
if (typeof exports === "object" && typeof module !== "undefined") {
33+
module['exports'] = factory();
34+
} else {
35+
// execute anyway
36+
return factory();
37+
}
3338
})(function() {
3439
// Define global variable
3540
var global = (typeof window === 'object' ? window : this) || {};

history.ielte7.min.js

Lines changed: 21 additions & 21 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

history.js

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* History API JavaScript Library v4.2.1
2+
* History API JavaScript Library v4.2.2
33
*
44
* Support: IE8+, FF3+, Opera 9+, Safari, Chrome and other
55
*
@@ -11,7 +11,7 @@
1111
* http://www.opensource.org/licenses/mit-license.php
1212
* http://www.gnu.org/licenses/gpl.html
1313
*
14-
* Update: 2015-05-22 13:02
14+
* Update: 2015-06-26 23:22
1515
*/
1616
(function(factory) {
1717
if (typeof define === 'function' && define['amd']) {
@@ -28,8 +28,13 @@
2828
};
2929
define([], factory);
3030
}
31-
// execute anyway
32-
factory();
31+
// commonJS support
32+
if (typeof exports === "object" && typeof module !== "undefined") {
33+
module['exports'] = factory();
34+
} else {
35+
// execute anyway
36+
return factory();
37+
}
3338
})(function() {
3439
// Define global variable
3540
var global = (typeof window === 'object' ? window : this) || {};

history.min.js

Lines changed: 15 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"*.js"
88
]
99
}],
10-
"version": "4.2.1",
10+
"version": "4.2.2",
1111
"description": "HTML5 History API expansion for browsers not supporting pushState, replaceState",
1212
"main": "history.js",
1313
"repository": {

0 commit comments

Comments
 (0)