Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

Commit

Permalink
feat: convert to TypeScript (#472)
Browse files Browse the repository at this point in the history
* feat: convert library to TypeScript

* test: system tests in TypeScript

* fix: run synthtool

* fix: no posttest please

* fix: docs

* fix: pr feedback, synthtool
  • Loading branch information
alexander-fenster committed Nov 22, 2019
1 parent cace910 commit c6d8145
Show file tree
Hide file tree
Showing 45 changed files with 1,485 additions and 4,728 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@ google-cloud-logging-winston-*.tgz
google-cloud-logging-bunyan-*.tgz
package-lock.json
__pycache__
.vscode/
dist/
2 changes: 1 addition & 1 deletion .jsdoc.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ module.exports = {
source: {
excludePattern: '(^|\\/|\\\\)[._]',
include: [
'src'
'build/src'
],
includePattern: '\\.js$'
},
Expand Down
41 changes: 26 additions & 15 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
"node": ">=8.10.0"
},
"repository": "googleapis/nodejs-speech",
"main": "./src/index.js",
"main": "./build/src/index.js",
"files": [
"protos",
"src",
"build/protos",
"build/src",
"AUTHORS",
"LICENSE"
],
Expand All @@ -29,40 +29,51 @@
"Google Cloud Speech API"
],
"scripts": {
"cover": "nyc --reporter=lcov mocha test/*.js && nyc report",
"docs": "jsdoc -c .jsdoc.js",
"lint": "eslint '**/*.js'",
"lint": "gts check && eslint samples/*.js samples/system-test/*.js system-test/*.js",
"samples-test": "cd samples/ && npm link ../ && npm test && cd ../",
"system-test": "mocha system-test/*.js --timeout 600000",
"test-no-cover": "mocha test/*.js",
"test": "npm run cover",
"fix": "eslint --fix '**/*.js'",
"system-test": "c8 mocha build/system-test/*.js --timeout 600000",
"test": "c8 mocha build/test/*.js",
"fix": "gts fix && eslint --fix samples/*.js samples/system-test/*.js system-test/*.js",
"docs-test": "linkinator docs",
"predocs-test": "npm run docs"
"predocs-test": "npm run docs",
"compile": "tsc -p . && cp system-test/*.js build/system-test/ && cp -r protos build/",
"prepare": "npm run compile",
"pretest": "npm run compile"
},
"dependencies": {
"@google-cloud/common": "^2.0.0",
"google-gax": "^1.7.5",
"google-gax": "^1.11.1",
"protobufjs": "^6.8.6",
"pumpify": "^2.0.0",
"stream-events": "^1.0.4"
"stream-events": "^1.0.4",
"@types/pumpify": "^1.4.1"
},
"devDependencies": {
"@types/mocha": "^5.2.7",
"@types/node": "^12.0.0",
"@types/sinon": "^7.5.1",
"c8": "^6.0.0",
"codecov": "^3.0.2",
"eslint": "^6.0.0",
"eslint-config-prettier": "^6.0.0",
"eslint-plugin-node": "^10.0.0",
"eslint-plugin-prettier": "^3.0.0",
"gts": "^1.1.2",
"intelli-espower-loader": "^1.0.1",
"jsdoc": "^3.5.5",
"jsdoc-fresh": "^1.0.1",
"jsdoc-region-tag": "^1.0.2",
"linkinator": "^1.5.0",
"mocha": "^6.0.0",
"nyc": "^14.0.0",
"null-loader": "^3.0.0",
"pack-n-play": "^1.0.0-2",
"power-assert": "^1.6.0",
"prettier": "^1.13.5",
"proxyquire": "^2.1.0",
"sinon": "^7.0.0"
"sinon": "^7.0.0",
"ts-loader": "^6.2.1",
"typescript": "~3.7.0",
"webpack": "^4.41.2",
"webpack-cli": "^3.3.10"
}
}
4 changes: 4 additions & 0 deletions prettier.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module.exports = {
singleQuote: true,
trailingComma: 'es5',
};
Loading

0 comments on commit c6d8145

Please sign in to comment.