Skip to content
This repository has been archived by the owner on Mar 5, 2021. It is now read-only.

Commit

Permalink
Update to TypeScript 2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
elisee committed Oct 29, 2016
1 parent f50b36d commit fc39b21
Show file tree
Hide file tree
Showing 12 changed files with 26 additions and 21 deletions.
8 changes: 4 additions & 4 deletions player/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ var gulp = require("gulp");

// TypeScript
var ts = require("gulp-typescript");
var tsProject = ts.createProject("src/tsconfig.json");
var tsProject = ts.createProject("tsconfig.json");
var tslint = require("gulp-tslint");

gulp.task("typescript", function() {
Expand All @@ -11,17 +11,17 @@ gulp.task("typescript", function() {
.pipe(tslint())
.pipe(tslint.report("prose", { emitError: true }))
.on("error", (err) => { throw err; })
.pipe(ts(tsProject))
.pipe(tsProject())
.on("error", () => { failed = true; })
.on("end", () => { if (failed) throw new Error("There were TypeScript errors."); });
return tsResult.js.pipe(gulp.dest("src/"));
return tsResult.js.pipe(gulp.dest("./"));
});

// Browserify
var browserify = require("browserify");
var source = require("vinyl-source-stream");
gulp.task("browserify", [ "typescript" ],function() {
var bundler = browserify("./src/index.js");
var bundler = browserify("./index.js");
function bundle() { return bundler.bundle().pipe(source("index.js")).pipe(gulp.dest("../public")); }
return bundle();
});
Expand Down
5 changes: 2 additions & 3 deletions player/src/index.ts → player/index.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
/// <reference path="../../../../typings/tsd.d.ts" />
/// <reference path="../../../../SupClient/typings/SupApp.d.ts" />
/// <reference path="../../../SupClient/typings/SupApp.d.ts" />

import * as async from "async";
import * as querystring from "querystring";
import supFetch from "../../../../SupClient/src/fetch";
import supFetch from "../../../SupClient/src/fetch";
import * as path from "path";

const statusElt = document.querySelector(".status") as HTMLDivElement;
Expand Down
7 changes: 0 additions & 7 deletions player/src/tsconfig.json

This file was deleted.

8 changes: 8 additions & 0 deletions player/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"compilerOptions": {
"module": "commonjs",
"target": "es5",
"noImplicitAny": true,
"typeRoots": [ "../../../node_modules/@types" ]
}
}
2 changes: 1 addition & 1 deletion plugins/common
Submodule common updated 39 files
+0 −1 documentation/index.d.ts
+3 −0 documentation/package.json
+2 −1 documentation/tsconfig.json
+0 −12 documentation/tsd.json
+0 −127 documentation/typings/marked/marked.d.ts
+0 −2 documentation/typings/tsd.d.ts
+18 −18 home/editors/main/index.ts
+10 −0 home/public/locales/it/home.json
+7 −0 home/public/locales/it/plugin.json
+10 −0 home/public/locales/ru/home.json
+7 −0 home/public/locales/ru/plugin.json
+2 −1 home/tsconfig.json
+7 −0 settings/public/locales/it/plugin.json
+6 −0 settings/public/locales/it/settingsEditors.json
+7 −0 settings/public/locales/ru/plugin.json
+6 −0 settings/public/locales/ru/settingsEditors.json
+2 −1 settings/tsconfig.json
+0 −2 textEditorWidget/index.d.ts
+2 −1 textEditorWidget/package.json
+2 −1 textEditorWidget/tsconfig.json
+0 −12 textEditorWidget/tsd.json
+0 −1,107 textEditorWidget/typings/codemirror/codemirror.d.ts
+0 −1 textEditorWidget/typings/tsd.d.ts
+1 −1 textEditorWidget/widget.d.ts
+2 −0 textEditorWidget/widget/widget.styl
+25 −21 textEditorWidget/widget/widget.ts
+1 −1 three/helpers.d.ts
+1 −3 three/helpers/GridHelper.ts
+1 −1 three/helpers/SelectionBoxRenderer.ts
+5 −6 three/helpers/TransformControls.ts
+0 −2 three/index.d.ts
+18 −11 three/main.d.ts
+2 −2 three/main/Camera.ts
+86 −18 three/main/Camera3DControls.ts
+3 −0 three/package.json
+2 −1 three/tsconfig.json
+0 −12 three/tsd.json
+0 −6,565 three/typings/threejs/three.d.ts
+0 −2 three/typings/tsd.d.ts
3 changes: 2 additions & 1 deletion plugins/default/blob/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"compilerOptions": {
"module": "commonjs",
"target": "es5",
"noImplicitAny": true
"noImplicitAny": true,
"typeRoots": [ "../../../../../node_modules/@types" ]
}
}
3 changes: 2 additions & 1 deletion plugins/default/export/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"compilerOptions": {
"module": "commonjs",
"target": "es5",
"noImplicitAny": true
"noImplicitAny": true,
"typeRoots": [ "../../../../../node_modules/@types" ]
}
}
3 changes: 2 additions & 1 deletion plugins/default/lua/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"compilerOptions": {
"module": "commonjs",
"target": "es5",
"noImplicitAny": true
"noImplicitAny": true,
"typeRoots": [ "../../../../../node_modules/@types" ]
}
}
2 changes: 1 addition & 1 deletion server/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ gulp.task("typescript", function() {
.pipe(tslint())
.pipe(tslint.report("prose", { emitError: true }))
.on("error", (err) => { throw err; })
.pipe(ts(tsProject))
.pipe(tsProject())
.on("error", () => { failed = true; })
.on("end", () => { if (failed) throw new Error("There were TypeScript errors."); });
return tsResult.js.pipe(gulp.dest("./"));
Expand Down
1 change: 0 additions & 1 deletion server/index.d.ts

This file was deleted.

2 changes: 2 additions & 0 deletions server/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
/// <reference path="../../../SupCore/SupCore.d.ts" />

import * as fs from "fs";
import * as async from "async";

Expand Down
3 changes: 2 additions & 1 deletion server/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"compilerOptions": {
"module": "commonjs",
"target": "es5",
"noImplicitAny": true
"noImplicitAny": true,
"typeRoots": [ "../../../node_modules/@types" ]
}
}

0 comments on commit fc39b21

Please sign in to comment.