chore: have 'use strict' consistently across our lib files (#14721)

This commit is contained in:
Samuel Attard 2018-09-23 00:28:50 +12:00 committed by GitHub
parent 0a621bfea1
commit 176a76217c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
57 changed files with 120 additions and 4 deletions

View file

@ -1,3 +1,5 @@
'use strict'
if (process.platform === 'win32') {
module.exports = require('@electron/internal/browser/api/auto-updater/auto-updater-win')
} else {

View file

@ -1,3 +1,5 @@
'use strict'
const EventEmitter = require('events').EventEmitter
const { autoUpdater, AutoUpdater } = process.atomBinding('auto_updater')

View file

@ -1,3 +1,5 @@
'use strict'
const fs = require('fs')
const path = require('path')
const spawn = require('child_process').spawn

View file

@ -1 +1,3 @@
'use strict'
module.exports = process.atomBinding('content_tracing')

View file

@ -1,3 +1,5 @@
'use strict'
const common = require('@electron/internal/common/api/exports/electron')
// since browser module list is also used in renderer, keep it separate.
const moduleList = require('@electron/internal/browser/api/module-list')

View file

@ -1 +1,3 @@
'use strict'
module.exports = process.atomBinding('global_shortcut').globalShortcut

View file

@ -1,3 +1,5 @@
'use strict'
const EventEmitter = require('events').EventEmitter
const emitter = new EventEmitter()

View file

@ -1,3 +1,5 @@
'use strict'
const { app } = require('electron')
const roles = {

View file

@ -1,3 +1,5 @@
'use strict'
function splitArray (arr, predicate) {
const result = arr.reduce((multi, item) => {
const current = multi[multi.length - 1]

View file

@ -1,3 +1,5 @@
'use strict'
const features = process.atomBinding('features')
// Browser side modules, please sort alphabetically.

View file

@ -1,3 +1,5 @@
'use strict'
const { EventEmitter } = require('events')
const { Notification, isSupported } = process.atomBinding('notification')

View file

@ -1,3 +1,5 @@
'use strict'
const { EventEmitter } = require('events')
const { powerMonitor, PowerMonitor } = process.atomBinding('power_monitor')

View file

@ -1 +1,3 @@
'use strict'
module.exports = process.atomBinding('power_save_blocker').powerSaveBlocker

View file

@ -1,3 +1,5 @@
'use strict'
const { app, session } = require('electron')
// Global protocol APIs.

View file

@ -1,3 +1,5 @@
'use strict'
const { EventEmitter } = require('events')
const { screen, Screen } = process.atomBinding('screen')

View file

@ -1,3 +1,5 @@
'use strict'
const { EventEmitter } = require('events')
const { app } = require('electron')
const { fromPartition, Session, Cookies } = process.atomBinding('session')

View file

@ -1,3 +1,5 @@
'use strict'
const { EventEmitter } = require('events')
const { systemPreferences, SystemPreferences } = process.atomBinding('system_preferences')

View file

@ -1,3 +1,5 @@
'use strict'
const { EventEmitter } = require('events')
let nextItemID = 1

View file

@ -1,3 +1,5 @@
'use strict'
const { EventEmitter } = require('events')
const { Tray } = process.atomBinding('tray')