mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
Reformat codebase into 2-spaces
This patch: - reformats codebase to use 2-spaces instead of 4. This will align the project with other codebases (e.g. DevTools and Lighthouse) - enables eslint indentation checking References #19
This commit is contained in:
parent
bbaf2f091c
commit
448ac4ce64
@ -100,12 +100,11 @@ module.exports = {
|
||||
"no-trailing-spaces": 2,
|
||||
"linebreak-style": [ 2, "unix" ],
|
||||
|
||||
"indent": [2, 2, { "SwitchCase": 1, "CallExpression": {"arguments": 2}, "MemberExpression": 2 }],
|
||||
/**
|
||||
* Disabled, aspirational rules
|
||||
*/
|
||||
|
||||
"indent": [0, 4, { "SwitchCase": 1, "CallExpression": {"arguments": 2}, "MemberExpression": 2 }],
|
||||
|
||||
// brace-style is disabled, as eslint cannot enforce 1tbs as default, but allman for functions
|
||||
"brace-style": [0, "allman", { "allowSingleLine": true }],
|
||||
|
||||
|
@ -23,9 +23,7 @@ if (Downloader.revisionInfo(Downloader.currentPlatform(), revision))
|
||||
return;
|
||||
|
||||
Downloader.downloadRevision(Downloader.currentPlatform(), revision, onProgress)
|
||||
.catch(error => {
|
||||
console.error('Download failed: ' + error.message);
|
||||
});
|
||||
.catch(error => console.error('Download failed: ' + error.message));
|
||||
|
||||
var progressBar = null;
|
||||
function onProgress(bytesTotal, delta) {
|
||||
|
@ -15,7 +15,6 @@
|
||||
*/
|
||||
|
||||
module.exports = {
|
||||
|
||||
/**
|
||||
* @param {function()} fun
|
||||
* @param {!Array<*>} args
|
||||
|
914
package-lock.json
generated
914
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -753,6 +753,10 @@ table@^4.0.1:
|
||||
slice-ansi "0.0.4"
|
||||
string-width "^2.0.0"
|
||||
|
||||
text-diff@^1.0.1:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/text-diff/-/text-diff-1.0.1.tgz#6c105905435e337857375c9d2f6ca63e453ff565"
|
||||
|
||||
text-table@~0.2.0:
|
||||
version "0.2.0"
|
||||
resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4"
|
||||
|
Loading…
Reference in New Issue
Block a user