Skip to content

Commit

Permalink
Set strictPropertyInitialization to true
Browse files Browse the repository at this point in the history
  • Loading branch information
xdan committed Feb 10, 2020
1 parent 67b09e3 commit 99b96b9
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 20 deletions.
18 changes: 9 additions & 9 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
"karma-mocha": "^1.3.0",
"karma-sourcemap-loader": "^0.3.7",
"karma-webpack": "^4.0.2",
"less": "^3.10.3",
"less": "^3.11.0",
"less-loader": "^4.1.0",
"lint-staged": "^8.2.1",
"merge-stream": "^2.0.0",
Expand Down
6 changes: 4 additions & 2 deletions src/modules/helpers/JoditArray.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@
import { extend } from './extend';

export class JoditArray {
public length: number = 0;
public toString() {
length: number = 0;

toString() {
const out = [];

for (let i = 0; i < this.length; i += 1) {
Expand All @@ -17,6 +18,7 @@ export class JoditArray {

return out.toString();
}

constructor(data: any[]) {
extend(true, this, data);
this.length = data.length;
Expand Down
4 changes: 2 additions & 2 deletions src/plugins/source/editor/engines/custom.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
* Copyright (c) 2013-2020 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
*/

import { IJodit, ISourceEditor } from '../../../../types';
import { ISourceEditor } from '../../../../types';
import { SourceEditor } from '../SourceEditor';

export class CustomEditor extends SourceEditor<HTMLTextAreaElement>
implements ISourceEditor {

init(editor: IJodit): any {
init(): any {
this.onReady();
}

Expand Down
17 changes: 11 additions & 6 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,31 @@
"target": "es5",
"moduleResolution": "node",

"resolveJsonModule": true,
"allowJs": true,

"removeComments": true,

"strict": true,
"strictNullChecks": true,
"strictFunctionTypes": true,
"strictBindCallApply": true,

"forceConsistentCasingInFileNames": true,
"strictPropertyInitialization": true,

"sourceMap": true,

"noImplicitAny": true,
"noImplicitReturns": true,
"noUnusedLocals": true,
"noUnusedParameters": false,
"noImplicitThis": true,

"importHelpers": true,
"forceConsistentCasingInFileNames": true,

"sourceMap": true,

"importHelpers": true,
"typeRoots": ["./node_modules/@types"],
"lib": ["es5", "esnext", "dom", "scripthost"]
},

"include": ["./src/**/*.ts", "./test/**/*.ts", "./types/**/*.d.ts"],
"exclude": ["node_modules", "build"]
}

0 comments on commit 99b96b9

Please sign in to comment.