UNPKG

3.68 kBMarkdownView Raw
1# Changelog
2
3### 7.1.0
4
5* Added Promise.prototype.finally
6
7### 7.0.2
8
9* Added IE8 compatability back to minify
10
11### 7.0.1
12
13* Fixed a bug in 'catch' keyword in IE8
14* Fixed import error when using `require`
15
16## 7.0.0
17
18* Updated code to ES6 module definitions (thanks Andarist)
19* Added polyfill.js file
20* move compiled files to dist folder
21
22## 6.1.0
23
24* Bug fix for non-array values in `Promise.all()`
25* Small optimization checking for making sure `Promise` is called with `new`
26
27## 6.0.0 Deprecated `Promise._setImmediateFn` and `Promise._setUnhandledRejectionFn`
28
29This allows subclassing Promise without rewriting functions
30
31* `Promise._setImmediateFn(<immediateFn>)` has been deprecated. Use `Promise._immediateFn = <immediateFn>` instead.
32* `Promise._setUnhandledRejectionFn(<rejectionFn>)` has been deprecated. Use `Promise._unhandledRejectionFn = <rejectionFn>` instead.
33 These functions will be removed in the next major version.
34
35### 5.2.1 setTimeout to 0
36
37Fixed bug where setTimeout was set to 1 instead of 0 for async execution
38
39### 5.2.0 Subclassing
40
41Allowed Subclassing. [#27](https://github.com/taylorhakes/promise-polyfill/pull/27)
42
43### 5.1.0 Fixed reliance on setTimeout
44
45Changed possibly unhanded warnings to use asap function instead of setTimeout
46
47## 5.0.0 Removed multiple params from Promise.all
48
49Removed non standard functionality of passing multiple params to Promise.all. You must pass an array now. You must change this code
50
51```js
52Promise.all(prom1, prom2, prom3);
53```
54
55to this
56
57```js
58Promise.all([prom1, prom2, prom3]);
59```
60
61### 4.0.4 IE8 console.warn fix
62
63IE8 does not have console, unless you open the developer tools. This fix checks to makes sure console.warn is defined before calling it.
64
65### 4.0.3 Fix case in bower.json
66
67bower.json had Promise.js instead of promise.js
68
69### 4.0.2 promise.js case fix in package.json
70
71Fixed promise.js in package.json. It was accidently published as Promise.js
72
73## 4.0.1 Unhandled Rejections and Other Fixes
74
75* Added unhandled rejection warnings to the console
76* Removed Grunt, jasmine and other unused code
77* Renamed Promise.js to lowercase promise.js in multiple places
78
79### 3.0.1 Fixed shadowing issue on setTimeout
80
81New version fixing this major bug https://github.com/taylorhakes/promise-polyfill/pull/17
82
83## 3.0.0 Updated setTimeout to not be affected by test mocks
84
85This is considered a breaking change because people may have been using this functionality. If you would like to keep version 2 functionality, set Promise.\_setImmediateFn on `promise-polyfill` like the code below.
86
87```js
88var Promise = require('promise-polyfill');
89Promise._setImmedateFn(function(fn) {
90 setTimeout(fn, 1);
91});
92```
93
94### 2.1.0 Promise.\_setImmedateFn
95
96Removed dead code Promise.immedateFn and added Promise.\_setImmediateFn(fn);
97
98### 2.0.2 Simplified Global detection
99
100Simplified attaching to global object
101
102### 2.0.1 Webworker bugfixes
103
104Fixed Webworkers missing window object
105
106## 2.0.0
107
108**Changed the following line**
109
110```
111module.exports = root.Promise ? root.Promise : Promise;
112```
113
114to
115
116```
117module.exports = Promise;
118```
119
120This means the library will not use built-in Promise by default. This allows for more consistency.
121
122You can easily add the functionality back.
123
124```
125var Promise = window.Promise || require('promise-polyfill');
126```
127
128**Added Promise.immediateFn to allow changing the setImmedate function**
129
130```
131Promise.immediateFn = window.setAsap;
132```
133
134### 1.1.4 Updated Promise to use correct global object in Browser and Node
135
136### 1.1.3 Fixed browserify issue with `this`
137
138### 1.1.2 Updated Promise.resolve to resolve with original Promise
139
140### 1.1.0 Performance Improvements for Modern Browsers
141
142## 1.0.1 Update README.md