mirror of
https://github.com/microsoft/monaco-editor.git
synced 2025-12-22 18:32:56 +01:00
Add strict TS checking
This commit is contained in:
parent
75cb14f8f0
commit
c0fb272a34
3 changed files with 9 additions and 8 deletions
|
|
@ -189,9 +189,9 @@ const keywords = [
|
||||||
|
|
||||||
// create case variations of the keywords - apex is case insensitive, but we can't make the highlighter case insensitive
|
// create case variations of the keywords - apex is case insensitive, but we can't make the highlighter case insensitive
|
||||||
// because we use a heuristic to assume that identifiers starting with an upper case letter are types.
|
// because we use a heuristic to assume that identifiers starting with an upper case letter are types.
|
||||||
const uppercaseFirstLetter = (lowercase) => lowercase.charAt(0).toUpperCase() + lowercase.substr(1);
|
const uppercaseFirstLetter = (lowercase: string) => lowercase.charAt(0).toUpperCase() + lowercase.substr(1);
|
||||||
|
|
||||||
let keywordsWithCaseVariations = [];
|
let keywordsWithCaseVariations: string[] = [];
|
||||||
keywords.forEach(lowercase => {
|
keywords.forEach(lowercase => {
|
||||||
keywordsWithCaseVariations.push(lowercase);
|
keywordsWithCaseVariations.push(lowercase);
|
||||||
keywordsWithCaseVariations.push(lowercase.toUpperCase());
|
keywordsWithCaseVariations.push(lowercase.toUpperCase());
|
||||||
|
|
|
||||||
12
src/mocha.d.ts
vendored
12
src/mocha.d.ts
vendored
|
|
@ -5,9 +5,9 @@
|
||||||
|
|
||||||
declare function run(): void;
|
declare function run(): void;
|
||||||
|
|
||||||
declare function suite(name: string, fn: (err?)=>void);
|
declare function suite(name: string, fn: (err?: any)=>void): void;
|
||||||
declare function test(name: string, fn: (done?: (err?)=>void)=>void);
|
declare function test(name: string, fn: (done: (err?: any)=>void)=>void): void;
|
||||||
declare function suiteSetup(fn: (done?: (err?)=>void)=>void);
|
declare function suiteSetup(fn: (done: (err?: any)=>void)=>void): void;
|
||||||
declare function suiteTeardown(fn: (done?: (err?)=>void)=>void);
|
declare function suiteTeardown(fn: (done: (err?: any)=>void)=>void): void;
|
||||||
declare function setup(fn: (done?: (err?)=>void)=>void);
|
declare function setup(fn: (done: (err?: any)=>void)=>void): void;
|
||||||
declare function teardown(fn: (done?: (err?)=>void)=>void);
|
declare function teardown(fn: (done: (err?: any)=>void)=>void): void;
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@
|
||||||
"module": "amd",
|
"module": "amd",
|
||||||
"outDir": "../release/dev",
|
"outDir": "../release/dev",
|
||||||
"target": "es5",
|
"target": "es5",
|
||||||
|
"strict": true,
|
||||||
"lib": [
|
"lib": [
|
||||||
"dom",
|
"dom",
|
||||||
"es5",
|
"es5",
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue