UNPKG

8.97 kBMarkdownView Raw
1# Change Log
2All notable changes to this project will be documented in this file.
3This project adheres to [Semantic Versioning](http://semver.org/).
4
5## 5.5.0 - 2019-02-06
6### Added
7- Added `domContentEventFired` so that `checkIfPageIsDoneLoading` will wait at least for `domContentEventFired` before also waiting for all network requests to finish. This should hopefully take care of any edge cases where a page is saved too early when Chrome doesn't send new network requests during the parsing of a large .js file.
8
9## 5.4.5 - 2018-12-04
10### Changed
11- fixed issue with creating browser tabs in a new context (to clear cookies/local storage)
12- `LOG_REQUESTS` shows console logging from the webpage being loaded
13- fixed `this.options.followRedirect` typo to now be `this.options.followRedirects`
14
15## 5.4.4 - 2018-08-07
16### Changed
17- Updated Mocha to 5.2.0, Sinon to 6.1.4 and a few minor package numbers
18- Added package-lock.json
19
20
21## 5.4.3 - 2018-08-07
22### Changed
23- Removed a check for success in the response of `Target.disposeBrowserContext` to fix an issue with Chrome 68 removing that response object.
24
25
26## 5.4.2 - 2018-04-05
27### Changed
28- Removed the `Page.addScriptToEvaluateOnNewDocument({source: 'localStorage.clear()'})` since it seemed to be causing an issue with Chrome in some cases. Going to look for a better fix here since our context should be clearing this already.
29
30
31## 5.4.1 - 2018-04-05
32### Changed
33- For checking if a URL returns a redirect, we were checking to see if the request returning the redirect URL matched which failed in some cases where the encoding of the URL was different in the request. That code now checks the request ID to see if it matches the original request.
34- Service worker enable/disable can be enabled/disabled on a per tab basis by setting `req.prerender.enableServiceWorker` in the `requestReceived` event.
35
36
37## 5.4.0 - 2018-04-04
38### Changed
39- Added ability to turn on/off services workers.
40
41
42## 5.3.1 - 2018-03-09
43### Added
44- Added `this.isBrowserConnected = false` inside `server.restartBrowser()` so the prerender server won't try to render any new requests before the browser is actually restarted. Fixes a very small edge case at scale.
45
46
47## 5.3.0 - 2018-03-09
48### Added
49- Added `localStorage.clear()` on a new page being loaded due to bug in BrowserContext local storage being cleared: https://bugs.chromium.org/p/chromium/issues/detail?id=754576
50
51### Changed
52- Changed `document.getElementsByTagName('html')[0].outerHTML` to `document.firstElementChild.outerHTML` when querying page `html` to improve performance.
53
54## 5.2.2 - 2018-02-02
55### Changed
56- Make sure we only call `Buffer.byteLength` on a string to fix an error in newer versions of Node
57
58## 5.2.1 - 2018-01-29
59### Changed
60- Changed `request.loaderId` to `request.requestId` in `requestWillBeSent` due to issue with Chrome 64 changing loaderId format.
61
62## 5.2.0 - 2017-12-08
63### Added
64- Added ability for the prerender server to restart Chrome due to some connection issues we've been seeing after a server is running for a few hours.
65
66## 5.1.1 - 2017-12-08
67### Changed
68- Chrome re-uses the original request ID on a redirect so we are saving off the fact that we saw a redirect to make sure we return a correct 301
69- Changed dependencies from ^ to ~ to make the semver more specific
70
71## 5.1.0 - 2017-12-06
72### Added
73- Added removal of `<link rel="import" src="">` tags after the page is done loading to the `removeScriptTags` plugin. Imported HTML can have script tags in it, and since it's already been rendered to the page we can safely remove it when running that plugin.
74
75## 5.0.3 - 2017-11-29
76### Added
77- Added `if (window.customElements) customElements.forcePolyfill = true`, `ShadyDOM = {force: true}`, and `ShadyCSS = {shimcssproperties: true}` to fix Polymer app rendering.
78
79## 5.0.2 - 2017-11-20
80### Changed
81- Added back `res.setHeader` for plugins to use
82
83## 5.0.1 - 2017-11-15
84### Changed
85- Set `renderType` to `html` for non "/render" endpoint
86
87## 5.0.0 - 2017-11-15
88### Added
89- Added Headless Chrome as a rendering engine!
90- Added new event types: `requestReceived`, `tabCreated`, `pageLoaded`.
91- Added new Prerender server option: `chromeLocation`
92- Added ability to request jpg and png screenshots
93- Added ability to request pdf export of a page
94- Added ability to request HAR file of page load times
95
96### Changed
97- Removed PhantomJS and all references to it
98- Removed old event types: `beforePhantomRequest`, `onPhantomPageCreate`, `afterPhantomRequest`, `beforeSend`
99- Removed In Memory Cache (moved to new repo)
100- Removed S3 HTML Cache (moved to new repo)
101- Removed Prerender server options that are no longer needed: `workers`, `iterations`, `softIterations`, `cookiesEnabled`, `pageDoneCheckTimeout`, `resourceDownloadTimeout`, `jsTimeout`, `noJsExecutionTimeout`, `evaluateJavascriptCheckTimeout`
102
103See the Readme.me for in depth descriptions of all of the new changes!
104
105## 4.4.1 - 2016-12-28
106### Changed
107- Whoops. Make sure `shouldEncodeURLBeforeBrowserFetch` defaults to true.
108
109## 4.4.0 - 2016-12-28
110### Added
111- Added `shouldEncodeURLBeforeBrowserFetch` to allow projects that use prerender to determine whether they want to call `encodeURI` on the URL before fetching it in PhantomJS. Useful for some URLs that might have encoded slashes in them, since encoding them further would cause incorrect behavior.
112
113## 4.3.1 - 2016-08-25
114### Changed
115- Fixed issue where PhantomJS crashed and then disposing caused bad phantomjs state
116
117## 4.3.0 - 2016-08-04
118### Changed
119- Bumped all dependency versions to latest
120
121## 4.2.0 - 2016-08-04
122### Added
123- Added ability for cluster master to kill last known phantomjs pid for a worker if the worker dies (preventing orphaned phantomjs instances)
124### Changed
125- Better terminating for cluster workers
126
127## 4.1.0 - 2016-07-27
128### Added
129- Added NUM_SOFT_ITERATIONS to try to kill phantomjs and reclaim memory when no requests are in flight. This should be set to a low number (1-10) so that PhantomJS can be restarted often when it isn't doing anything else. NUM_ITERATIONS should still be set to something like 40-50 to make sure to force kill PhantomJS even if a request is in flight.
130- Added clearing of memory cache to prevent PhantomJS from returning a 304
131### Changed
132- Fixed issue where prerender-status-code set to `200` was causing the page to skip being cached
133- Fixed an issue where we weren't using the correct pid when trying to force kill PhantomJS.
134- Moved clearing of memory cache and local storage to before the page loads instead of after. This will prevent edge cases that could cause a 304.
135
136## 4.0.10 - 2016-06-01
137### Changed
138- Fixed issue where S3HtmlCache was calling next() before finishing saving to the cache
139
140## 4.0.9 - 2016-05-08
141### Changed
142- Fixed issue where we were calling `hasOwnProperty` on a `querystring` that no longer had Object on it's prototype chain
143
144## 4.0.8 - 2016-03-24
145### Changed
146- Fixed issue where a webpage calling window.close would cause Prerender to be unable to shutdown PhantomJS properly
147
148## 4.0.7 - 2016-03-22
149### Changed
150- S3 cache plugin was incorrectly saving non-200 status code responses to the cache
151
152## 4.0.6 - 2016-03-09
153### Changed
154- preserve phantom arguments when server is restarting
155- use default when phantomArguments is empty
156
157## 4.0.5 - 2016-02-29
158### Changed
159- prevent multiple phantomjs instances from being started with low number of iterations
160- try to check to see if phantomjs has actually been disposed. if not, force kill it.
161
162## 4.0.4 - 2016-02-18
163### Changed
164- added engines to package.json and fixed possible bug in checking options passed in
165- prevent weird hangup on error setting a header with a newline
166- make sure we catch any errors thrown from phridge and continue
167- kill workers (and phantomjs) on SIGTERM
168
169## 4.0.3 - 2016-02-12
170### Added plugin to send a header of X-Prerender: 1 with every request
171
172## 4.0.2 - 2016-02-12
173#### Now using PhantomJS version 2.1
174### Changed
175- Changed `PHANTOM_CLUSTER_NUM_WORKERS` to `PRERENDER_NUM_WORKERS` in server.js
176- Changed `PHANTOM_WORKER_ITERATIONS` to `PRERENDER_NUM_ITERATIONS` in server.js
177- Switched from `phantomjs-node` bridge to `phridge`
178 - All Prerender plugins that access PhantomJS need to be rewritten to support new [phridge](https://github.com/peerigon/phridge) integration.
179 For example, change this:
180 ```
181 req.prerender.page.set('onConsoleMessage', function(msg) {
182 console.log(msg);
183 });
184 ```
185 to this:
186 ```
187 req.prerender.page.run(function() {
188
189 this.onConsoleMessage = function(msg) {
190 console.log(msg);
191 };
192 });
193 ```
194 Please see [phridge](https://github.com/peerigon/phridge) for more info on how to interact with PhantomJS through `phridge`.
195
196 ###Removed
197 - Removed `PHANTOM_CLUSTER_BASE_PORT` since `phridge` doesn't start a webserve to talk to PhantomJS, so it's no longer needed.
198 - Removed `PHANTOM_CLUSTER_MESSAGE_TIMEOUT` since `phridge` doesn't start a webserve to talk to PhantomJS, so it's no longer needed.
199
\No newline at end of file