Skip to content

Commit ff0e5f1

Browse files
Merge branch 'master' of github.com:watson-developer-cloud/speech-javascript-sdk
2 parents a3da9fd + ef09d1a commit ff0e5f1

8 files changed

+4865
-1213
lines changed

Diff for: .eslintrc.js

+15-21
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,24 @@
11
module.exports = {
2-
"parser": "esprima",
3-
"env": {
4-
"node": true,
5-
"browser": true,
2+
parser: 'esprima',
3+
env: {
4+
node: true,
5+
browser: true,
66
},
7-
'globals': {
7+
globals: {
88
// we want to enable a limited sub-set of ES6 features
99
// this library should (partially) work even in IE
1010
// false meaning this code doesn't define it
1111
Promise: false,
1212
DataView: false,
1313
ArrayBuffer: false,
14-
Float32Array: false
14+
Float32Array: false,
1515
},
16-
"plugins": [
17-
"prettier",
18-
],
19-
"extends": [
20-
"eslint:recommended",
21-
"prettier",
22-
],
23-
"rules": {
24-
"prettier/prettier": ["error", {"singleQuote": true, "printWidth": 160}],
25-
"no-var": "off",
26-
"prefer-const": "off",
27-
"prefer-rest-params": "off",
28-
"prefer-spread": "off",
29-
}
30-
};
16+
plugins: ['prettier'],
17+
extends: ['eslint:recommended', 'prettier'],
18+
rules: {
19+
'no-var': 'off',
20+
'prefer-const': 'off',
21+
'prefer-rest-params': 'off',
22+
'prefer-spread': 'off',
23+
},
24+
}

Diff for: .prettierrc

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"trailingComma": "es5",
3+
"tabWidth": 2,
4+
"semi": true,
5+
"singleQuote": true,
6+
"arrowParens": "always",
7+
"printWidth": 160
8+
}

Diff for: bower.json

+4-20
Original file line numberDiff line numberDiff line change
@@ -2,26 +2,10 @@
22
"name": "watson-speech",
33
"description": "IBM Watson Speech to Text and Text to Speech SDK for web browsers.",
44
"main": "dist/watson-speech.js",
5-
"authors": [
6-
"Nathan Friedly <http://nfriedly.com>"
7-
],
5+
"authors": ["Nathan Friedly <http://nfriedly.com>"],
86
"license": "Apache-2.0",
9-
"keywords": [
10-
"voice",
11-
"recognition",
12-
"speech",
13-
"text",
14-
"transcription",
15-
"synthesis"
16-
],
17-
"moduleType": [
18-
"amd",
19-
"globals",
20-
"node"
21-
],
7+
"keywords": ["voice", "recognition", "speech", "text", "transcription", "synthesis"],
8+
"moduleType": ["amd", "globals", "node"],
229
"homepage": "https://watson-speech.mybluemix.net/",
23-
"ignore": [
24-
"**/*",
25-
"!dist/*.js"
26-
]
10+
"ignore": ["**/*", "!dist/*.js"]
2711
}

Diff for: karma.conf.js

+9-9
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@ module.exports = function(config) {
2424
// preprocess matching files before serving them to the browser
2525
// available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
2626
preprocessors: {
27-
'test/*-spec.js': ['browserify']
27+
'test/*-spec.js': ['browserify'],
2828
},
2929
browserify: {
3030
debug: true,
3131
// 'brfs' makes fs.read* work
3232
// 'browserify-shim' wraps non-browserify modules
3333
// 'envify' makes process.env work
34-
transform: ['envify']
34+
transform: ['envify'],
3535
},
3636
// test results reporter to use
3737
// possible values: 'dots', 'progress'
@@ -59,16 +59,16 @@ module.exports = function(config) {
5959
'--use-fake-device-for-media-stream',
6060
'--use-fake-ui-for-media-stream',
6161
'--use-file-for-fake-audio-capture=' + path.join(__dirname, 'test/resources/audio.wav'),
62-
'--no-sandbox'
63-
]
62+
'--no-sandbox',
63+
],
6464
},
6565
// automatically approve getUserMedia calls
6666
FirefoxAutoGUM: {
6767
base: 'Firefox',
6868
prefs: {
69-
'media.navigator.permission.disabled': true
70-
}
71-
}
69+
'media.navigator.permission.disabled': true,
70+
},
71+
},
7272
},
7373
// Continuous Integration mode
7474
// if true, Karma captures browsers, runs the tests and exits
@@ -80,10 +80,10 @@ module.exports = function(config) {
8080
port: 9877,
8181
// this function takes express app object and allows you to modify it
8282
// to your liking. For more see http://expressjs.com/4x/api.html
83-
appVisitor: testServer
83+
appVisitor: testServer,
8484
},
8585
browserDisconnectTimeout: 15000,
8686
browserDisconnectTolerance: 2,
87-
browserNoActivityTimeout: 30000
87+
browserNoActivityTimeout: 30000,
8888
});
8989
};

0 commit comments

Comments
 (0)