Skip to content

Commit 280b155

Browse files
committed
feat: Update all dependencies + Fix lint issues
1 parent e2415b6 commit 280b155

File tree

21 files changed

+2886
-1489
lines changed

21 files changed

+2886
-1489
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,4 @@ lint-results.json
3131

3232
# legacy
3333
!/packages/raven-js/dist
34+
tmp.js

packages/browser/package.json

Lines changed: 32 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -21,35 +21,49 @@
2121
"tslib": "^1.9.3"
2222
},
2323
"devDependencies": {
24-
"@types/md5": "2.1.32",
24+
"@google-cloud/storage": "^2.4.2",
25+
"@types/jest": "^24.0.6",
26+
"@types/md5": "2.1.33",
27+
"@types/mocha": "^5.2.6",
28+
"@types/node": "^11.9.4",
29+
"@types/raven": "^2.5.3",
30+
"@types/sinon": "^7.0.6",
2531
"chai": "^4.1.2",
26-
"jsdom": "^11.12.0",
27-
"karma": "^2.0.2",
32+
"codecov": "^3.2.0",
33+
"danger": "^7.0.12",
34+
"jest": "^24.1.0",
35+
"jsdom": "^13.2.0",
36+
"karma": "^4.0.0",
2837
"karma-chai": "^0.1.0",
2938
"karma-chrome-launcher": "^2.2.0",
3039
"karma-failed-reporter": "0.0.3",
3140
"karma-firefox-launcher": "^1.1.0",
3241
"karma-mocha": "^1.3.0",
3342
"karma-mocha-reporter": "^2.2.5",
34-
"karma-rollup-preprocessor": "^6.0.0",
35-
"karma-sauce-launcher": "^1.2.0",
36-
"karma-typescript": "^3.0.12",
37-
"karma-typescript-es6-transform": "^1.0.4",
43+
"karma-rollup-preprocessor": "^7.0.0",
44+
"karma-sauce-launcher": "^2.0.2",
45+
"karma-typescript": "^4.0.0",
46+
"karma-typescript-es6-transform": "^4.0.0",
47+
"lerna": "3.13.0",
48+
"mocha": "^5.2.0",
3849
"npm-run-all": "^4.1.2",
39-
"prettier": "^1.14.0",
50+
"prettier": "^1.16.4",
4051
"prettier-check": "^2.0.0",
41-
"rimraf": "^2.6.2",
42-
"rollup": "^0.58.2",
52+
"replace-in-file": "^3.4.3",
53+
"rimraf": "^2.6.3",
54+
"rollup": "^1.2.1",
4355
"rollup-plugin-commonjs": "^9.1.3",
44-
"rollup-plugin-license": "^0.6.0",
45-
"rollup-plugin-node-resolve": "^3.3.0",
56+
"rollup-plugin-license": "^0.8.1",
57+
"rollup-plugin-node-resolve": "^4.0.0",
4658
"rollup-plugin-npm": "^2.0.0",
47-
"rollup-plugin-typescript2": "^0.13.0",
48-
"rollup-plugin-uglify": "^3.0.0",
49-
"sinon": "^5.0.3",
50-
"tslint": "^5.11.0",
51-
"typescript": "^3.2.0",
52-
"webpack": "^4.26.0"
59+
"rollup-plugin-typescript2": "^0.19.2",
60+
"rollup-plugin-uglify": "^6.0.2",
61+
"sinon": "^7.2.3",
62+
"tslint": "^5.12.1",
63+
"typedoc": "^0.14.2",
64+
"typescript": "^3.3.3",
65+
"typescript-tslint-plugin": "^0.3.1",
66+
"webpack": "^4.29.4"
5367
},
5468
"scripts": {
5569
"build": "run-p build:esm build:es5",

packages/browser/rollup.config.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import commonjs from 'rollup-plugin-commonjs';
2-
import uglify from 'rollup-plugin-uglify';
2+
import { uglify } from 'rollup-plugin-uglify';
33
import resolve from 'rollup-plugin-node-resolve';
44
import typescript from 'rollup-plugin-typescript2';
55
import license from 'rollup-plugin-license';
@@ -32,6 +32,7 @@ const bundleConfig = {
3232
tsconfigOverride: {
3333
compilerOptions: {
3434
declaration: false,
35+
module: 'ES2015',
3536
paths: {
3637
'@sentry/utils/*': ['../utils/src/*'],
3738
'@sentry/core': ['../core/src'],
@@ -72,6 +73,7 @@ export default [
7273
tsconfig: 'tsconfig.build.json',
7374
tsconfigOverride: {
7475
compilerOptions: {
76+
module: 'ES2015',
7577
rootDir: 'src',
7678
},
7779
},

packages/core/package.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,14 @@
2222
"tslib": "^1.9.3"
2323
},
2424
"devDependencies": {
25-
"jest": "^22.4.3",
25+
"jest": "^24.1.0",
2626
"npm-run-all": "^4.1.2",
27-
"prettier": "^1.14.0",
27+
"prettier": "^1.16.4",
2828
"prettier-check": "^2.0.0",
29-
"rimraf": "^2.6.2",
30-
"tslint": "^5.11.0",
31-
"typescript": "^3.2.0"
29+
"rimraf": "^2.6.3",
30+
"ts-jest": "^23.10.5",
31+
"tslint": "^5.12.1",
32+
"typescript": "^3.3.3"
3233
},
3334
"scripts": {
3435
"build": "run-p build:es5 build:esm",

packages/core/src/basebackend.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,7 @@ export interface Backend {
4848
* A class object that can instanciate Backend objects.
4949
* @hidden
5050
*/
51-
export interface BackendClass<B extends Backend, O extends Options> {
52-
new (options: O): B;
53-
}
51+
export type BackendClass<B extends Backend, O extends Options> = new (options: O) => B;
5452

5553
/**
5654
* This is the base implemention of a Backend.

packages/core/src/sdk.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,7 @@ import { Client, Options } from '@sentry/types';
33
import { logger } from '@sentry/utils/logger';
44

55
/** A class object that can instanciate Client objects. */
6-
export interface ClientClass<F extends Client, O extends Options> {
7-
new (options: O): F;
8-
}
6+
export type ClientClass<F extends Client, O extends Options> = new (options: O) => F;
97

108
/**
119
* Internal function to create a new SDK client instance. The client is

packages/hub/package.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,14 @@
2020
"tslib": "^1.9.3"
2121
},
2222
"devDependencies": {
23-
"jest": "^22.4.3",
23+
"jest": "^24.1.0",
2424
"npm-run-all": "^4.1.2",
25-
"prettier": "^1.14.0",
25+
"prettier": "^1.16.4",
2626
"prettier-check": "^2.0.0",
27-
"rimraf": "^2.6.2",
28-
"tslint": "^5.11.0",
29-
"typescript": "^3.2.0"
27+
"rimraf": "^2.6.3",
28+
"ts-jest": "^23.10.5",
29+
"tslint": "^5.12.1",
30+
"typescript": "^3.3.3"
3031
},
3132
"scripts": {
3233
"build": "run-p build:es5 build:esm",

packages/hub/src/hub.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ export class Hub {
148148
*
149149
* @param callback that will be enclosed into push/popScope.
150150
*/
151-
public withScope(callback: ((scope: Scope) => void)): void {
151+
public withScope(callback: (scope: Scope) => void): void {
152152
const scope = this.pushScope();
153153
try {
154154
callback(scope);
@@ -287,7 +287,7 @@ export class Hub {
287287
* This function is useful if you want to run your own client and hook into an already initialized one
288288
* e.g.: Reporting issues to your own sentry when running in your component while still using the users configuration.
289289
*/
290-
public run(callback: ((hub: Hub) => void)): void {
290+
public run(callback: (hub: Hub) => void): void {
291291
const oldHub = makeMain(this);
292292
try {
293293
callback(this);

packages/minimal/package.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,14 @@
2020
"tslib": "^1.9.3"
2121
},
2222
"devDependencies": {
23-
"jest": "^22.4.3",
23+
"jest": "^24.1.0",
2424
"npm-run-all": "^4.1.2",
25-
"prettier": "^1.14.0",
25+
"prettier": "^1.16.4",
2626
"prettier-check": "^2.0.0",
27-
"rimraf": "^2.6.2",
28-
"tslint": "^5.11.0",
29-
"typescript": "^3.2.0"
27+
"rimraf": "^2.6.3",
28+
"ts-jest": "^23.10.5",
29+
"tslint": "^5.12.1",
30+
"typescript": "^3.3.3"
3031
},
3132
"scripts": {
3233
"build": "run-p build:es5 build:esm",

packages/minimal/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ export function configureScope(callback: (scope: Scope) => void): void {
9797
*
9898
* @param callback that will be enclosed into push/popScope.
9999
*/
100-
export function withScope(callback: ((scope: Scope) => void)): void {
100+
export function withScope(callback: (scope: Scope) => void): void {
101101
callOnHub<void>('withScope', callback);
102102
}
103103

packages/node/package.json

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,17 +28,18 @@
2828
"tslib": "^1.9.3"
2929
},
3030
"devDependencies": {
31-
"@types/cookie": "0.3.1",
31+
"@types/cookie": "0.3.2",
3232
"@types/lru-cache": "^4.1.1",
33-
"@types/node": "^10.12.10",
33+
"@types/node": "^11.9.4",
3434
"express": "^4.16.4",
35-
"jest": "^22.4.3",
35+
"jest": "^24.1.0",
3636
"npm-run-all": "^4.1.2",
37-
"prettier": "^1.14.0",
37+
"prettier": "^1.16.4",
3838
"prettier-check": "^2.0.0",
39-
"rimraf": "^2.6.2",
40-
"tslint": "^5.11.0",
41-
"typescript": "^3.2.0"
39+
"rimraf": "^2.6.3",
40+
"ts-jest": "^23.10.5",
41+
"tslint": "^5.12.1",
42+
"typescript": "^3.3.3"
4243
},
4344
"scripts": {
4445
"build": "tsc -p tsconfig.build.json",

packages/node/src/integrations/onuncaughtexception.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,11 @@ export class OnUncaughtException implements Integration {
2626
*/
2727
public constructor(
2828
private readonly options: {
29+
/**
30+
* Default onFatalError handler
31+
* @param firstError Error that has been thrown
32+
* @param secondError If this was called multiple times this will be set
33+
*/
2934
onFatalError?(firstError: Error, secondError?: Error): void;
3035
} = {},
3136
) {}

packages/node/src/transports/base.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@ import { SDK_NAME, SDK_VERSION } from '../version';
1313
* @hidden
1414
*/
1515
export interface HTTPRequest {
16+
/**
17+
* Request wrapper
18+
* @param options These are {@see TransportOptions}
19+
* @param callback Callback when request is finished
20+
*/
1621
request(
1722
options: http.RequestOptions | https.RequestOptions | string | url.URL,
1823
callback?: (res: http.IncomingMessage) => void,

packages/types/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@
1616
},
1717
"devDependencies": {
1818
"npm-run-all": "^4.1.2",
19-
"prettier": "^1.14.0",
19+
"prettier": "^1.16.4",
2020
"prettier-check": "^2.0.0",
21-
"tslint": "^5.11.0",
22-
"typescript": "^3.2.0"
21+
"tslint": "^5.12.1",
22+
"typescript": "^3.3.3"
2323
},
2424
"scripts": {
2525
"build": "run-p build:es5 build:esm",

packages/types/src/integration.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ export interface Integration {
1414
*/
1515
name: string;
1616

17-
// This takes no options on purpose, options should be passed in the constructor
17+
/**
18+
* Sets the integration up only once.
19+
* This takes no options on purpose, options should be passed in the constructor
20+
*/
1821
setupOnce(): void;
1922
}

packages/types/src/transport.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,7 @@ export interface Transport {
1919
}
2020

2121
/** JSDoc */
22-
export interface TransportClass<T extends Transport> {
23-
new (options: TransportOptions): T;
24-
}
22+
export type TransportClass<T extends Transport> = new (options: TransportOptions) => T;
2523

2624
/** JSDoc */
2725
export interface TransportOptions {

packages/typescript/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"access": "public"
1212
},
1313
"dependencies": {
14-
"tslint-config-prettier": "^1.12.0"
14+
"tslint-config-prettier": "^1.18.0"
1515
},
1616
"peerDependencies": {
1717
"tslint": "^5.11.0",

packages/typescript/tslint.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
"prefer-function-over-method": [false],
1616
"strict-boolean-expressions": false,
1717
"no-inferrable-types": false,
18+
"ban-ts-ignore": false,
19+
"increment-decrement": false,
1820
// These are too strict in tslint:all
1921
"comment-format": [true, "check-space"],
2022
"completed-docs": [
@@ -26,7 +28,7 @@
2628
"functions": { "tags": { "content": {}, "existence": ["inheritDoc", "hidden"] } },
2729
"interfaces": { "tags": { "content": {}, "existence": ["inheritDoc", "hidden"] } },
2830
"methods": { "tags": { "content": {}, "existence": ["inheritDoc", "hidden"] } },
29-
"properties": { "tags": { "content": {}, "existence": ["inheritDoc", "hidden"] } }
31+
"properties": { "tags": { "content": {}, "existence": ["inheritDoc", "hidden"] }, "locations": "instance" }
3032
}
3133
],
3234
"interface-name": [true, "never-prefix"],

packages/utils/package.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,14 @@
1818
},
1919
"devDependencies": {
2020
"chai": "^4.1.2",
21-
"jest": "^22.4.3",
21+
"jest": "^24.1.0",
2222
"npm-run-all": "^4.1.2",
23-
"prettier": "^1.14.0",
23+
"prettier": "^1.16.4",
2424
"prettier-check": "^2.0.0",
25-
"rimraf": "^2.6.2",
26-
"tslint": "^5.11.0",
27-
"typescript": "^3.2.0"
25+
"rimraf": "^2.6.3",
26+
"ts-jest": "^23.10.5",
27+
"tslint": "^5.12.1",
28+
"typescript": "^3.3.3"
2829
},
2930
"scripts": {
3031
"build": "run-s clean && run-p build:es5 build:esm",

packages/utils/src/syncpromise.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ type HandlerOnFail<U = any> = (reason: any) => U | Thenable<U>;
2121

2222
/** JSDoc */
2323
interface Thenable<T> {
24+
/** JSDoc */
2425
then<U>(onSuccess?: HandlerOnSuccess<T, U>, onFail?: HandlerOnFail<U> | ((reason: any) => void)): Thenable<U>;
2526
}
2627

0 commit comments

Comments
 (0)