Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enabling typedef tslint rule for taco packages #58

Merged
merged 11 commits into from Oct 8, 2015
Merged

Conversation

nisheetjain
Copy link
Member

No description provided.

Conflicts:
	src/remotebuild/resources/en/resources.json
taco-dependency-installer,taco-kits,taco-remote,taco-remote-lib,taco-remote-multiplexer,taco-utils
private static debug = false;
private static CERT_DEFAULTS = {
private static debug: boolean = false;
private static CERT_DEFAULTS: any = {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please put the proper type for this variable. With any, you can use any members, like dayss and the compiler will allow it. If you leave it untyped, typescript deduces the proper type, so trying to use Certs.CERT_DEFAULTS.dayss gives this error:
remotebuild\lib\darwin\darwinCerts.ts(227,64): error TS2339: Property 'dayss' does not exist on type '{ days: number; country: string; ca_cn: string; pfx_name: string; client_cn: string; }'.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Incorporating PR feedback from @digeff
Conflicts:
	src/taco-cli/cli/plugin.ts
	src/taco-cli/test/cordovaWrapper.ts
Conflicts:
	src/taco-cli/cli/build.ts
	src/taco-cli/cli/utils/buildTelemetryHelper.ts
	src/taco-cli/cli/utils/settings.ts
	src/taco-cli/test/platformHelper.ts
var valueToSerialize: string = kitProject ? self.commandParameters.data.options["kit"] : self.commandParameters.data.options["cordova"];

return projectHelper.createTacoJsonFile(self.commandParameters.cordovaParameters.projectPath, kitProject, valueToSerialize);
})
.then(function (): Q.Promise<any> {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like the space between "function" and "()" has been deleted in some files but not in many other files. Lets be consistent here.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@@ -122,7 +122,7 @@ describe("server", function (): void {
fs.existsSync(path.join(certsDir, "ca-key.pem")).should.be.ok;
fs.existsSync(path.join(certsDir, "ca-cert.pem")).should.be.ok;
}).then(function (): Q.Promise<{}> {
var deferred = Q.defer();
var deferred: Q.Deferred<any> = Q.defer();
// Disabling strict SSL for unit testing
request.get({ url: "https://localhost:3000", strictSSL: false }, function (error: any, response: any, body: any): void {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to this file: https://github.com/borisyankov/DefinitelyTyped/blob/master/request/request.d.ts it seems that response is a http.IncomingMessage

@meenakb
Copy link
Contributor

meenakb commented Oct 7, 2015

👍 with comments above.

keeping type inferences work by themselves for anonymous objects
Conflicts:
	src/taco-utils/tacoPackageLoader.ts
nisheetjain added a commit that referenced this pull request Oct 8, 2015
Enabling typedef tslint rule (with variable-declaration off) for taco packages
@nisheetjain nisheetjain merged commit 8513e90 into master Oct 8, 2015
@nisheetjain nisheetjain deleted the tslint3 branch October 8, 2015 07:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants