Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 60308d1

Browse files
christopherthielenmergify[bot]
authored andcommitted
chore(lint): remove tslint from the project
1 parent 07775e2 commit 60308d1

File tree

11 files changed

+30
-184
lines changed

11 files changed

+30
-184
lines changed

‎.eslintrc.js‎

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
1-
/*
2-
👋 Hi! This file was autogenerated by tslint-to-eslint-config.
3-
https://github.com/typescript-eslint/tslint-to-eslint-config
4-
5-
It represents the closest reasonable ESLint configuration to this
6-
project's original TSLint configuration.
7-
8-
We recommend eventually switching this configuration to extend from
9-
the recommended rulesets in typescript-eslint.
10-
https://github.com/typescript-eslint/tslint-to-eslint-config/blob/master/docs/FAQs.md
11-
12-
Happy linting! 💖
13-
*/
1+
// eslint-disable-next-line no-undef
142
module.exports = {
153
env: { browser: true },
164
parser: '@typescript-eslint/parser',
175
plugins: ['@typescript-eslint'],
186
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'prettier', 'prettier/@typescript-eslint'],
19-
rules: {},
7+
rules: {
8+
'@typescript-eslint/no-explicit-any': 'off',
9+
'@typescript-eslint/explicit-module-boundary-types': 'off',
10+
11+
'@typescript-eslint/ban-types': [
12+
'error',
13+
{
14+
types: {
15+
Function: false,
16+
},
17+
},
18+
],
19+
},
2020
};

‎.npmignore‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ bower.json
1111
karma.conf.js
1212
tsconfig.json
1313
tsconfig.**.json
14-
tslint.json
1514
webpack.config.js
1615

1716
*.iml

‎package.json‎

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,6 @@
8585
"@types/angular-mocks": "^1.7.0",
8686
"@types/jest": "^26.0.5",
8787
"@typescript-eslint/eslint-plugin": "^3.7.0",
88-
"@typescript-eslint/eslint-plugin-tslint": "^3.7.0",
8988
"@typescript-eslint/parser": "^3.7.0",
9089
"@uirouter/publish-scripts": "2.5.3",
9190
"angular": "1.8.0",
@@ -104,8 +103,6 @@
104103
"rollup-plugin-sourcemaps": "^0.6.2",
105104
"rollup-plugin-terser": "^6.1.0",
106105
"ts-jest": "^26.0.0",
107-
"tslint": "5.20.1",
108-
"tslint-eslint-rules": "^5.4.0",
109106
"typescript": "^3.9.7",
110107
"utf-8-validate": "5.0.2"
111108
},
@@ -134,7 +131,7 @@
134131
"Components": [
135132
"uiView",
136133
"UISref",
137-
"UISrefActive"
134+
"UISrefActive","uiStateDirective"
138135
],
139136
"Other": [
140137
"Transition",

‎src/angular.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @publicapi @module ng1 */ /** */
22
import * as ng_from_import from 'angular';
3-
/** @hidden */ declare var angular;
3+
/** @hidden */ declare let angular;
44
/** @hidden */ const ng_from_global = angular;
55
/** @hidden */ export const ng = ng_from_import && ng_from_import.module ? ng_from_import : ng_from_global;

‎src/directives/stateDirectives.ts‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ import {
3434
import { UIViewData } from './viewDirective';
3535

3636
/** @hidden Used for typedoc */
37-
export interface ng1_directive {}// tslint:disable-line:class-name
37+
export interface ng1_directive {}
3838

3939
/** @hidden */
4040
function parseStateRef(ref: string) {
@@ -294,7 +294,6 @@ uiSrefDirective = [
294294
const type = getTypeInfo(element);
295295
const active = uiSrefActive[1] || uiSrefActive[0];
296296
let unlinkInfoFn: Function = null;
297-
let hookFn;
298297

299298
const rawDef = {} as Def;
300299
const getDef = () => processedDef($state, element, rawDef);
@@ -328,7 +327,7 @@ uiSrefDirective = [
328327
scope.$on('$destroy', <any>$uiRouter.transitionService.onSuccess({}, update));
329328

330329
if (!type.clickable) return;
331-
hookFn = clickHook(element, $state, $timeout, type, getDef);
330+
consthookFn = clickHook(element, $state, $timeout, type, getDef);
332331
bindEvents(element, scope, hookFn, rawDef.uiStateOpts);
333332
},
334333
};

‎src/injectables.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/* eslint-disable @typescript-eslint/no-unused-vars */
12
/**
23
* # Angular 1 injectable services
34
*
@@ -48,7 +49,6 @@
4849
*
4950
* @preferred @publicapi @module injectables
5051
*/ /** */
51-
/* tslint:disable:prefer-const */
5252
import { StateProvider } from './stateProvider';
5353
import {
5454
StateService,

‎src/interface.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ export interface Ng1StateTransitionHook {
5050
*
5151
* Used to reset [[StateDeclaration]] typings to `any` so the [[Ng1StateDeclaration]] interface can then narrow them */
5252
export interface _Ng1StateDeclaration extends StateDeclaration {
53-
// tslint:disable-line:class-name
5453
onExit?: any;
5554
onRetain?: any;
5655
onEnter?: any;

‎src/services.ts‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,19 +37,18 @@ import { StateProvider } from './stateProvider';
3737
import { getStateHookBuilder } from './statebuilders/onEnterExitRetain';
3838
import { Ng1LocationServices } from './locationServices';
3939
import { UrlRouterProvider } from './urlRouterProvider';
40-
import IInjectorService = angular.auto.IInjectorService;// tslint:disable-line
40+
import IInjectorService = angular.auto.IInjectorService;
4141

4242
angular.module('ui.router.angular1', []);
4343
const mod_init = angular.module('ui.router.init', ['ng']);
4444
const mod_util = angular.module('ui.router.util', ['ui.router.init']);
4545
const mod_rtr = angular.module('ui.router.router', ['ui.router.util']);
4646
const mod_state = angular.module('ui.router.state', ['ui.router.router', 'ui.router.util', 'ui.router.angular1']);
4747
const mod_main = angular.module('ui.router', ['ui.router.init', 'ui.router.state', 'ui.router.angular1']);
48-
const mod_cmpt = angular.module('ui.router.compat', ['ui.router']);// tslint:disable-line
48+
const mod_cmpt = angular.module('ui.router.compat', ['ui.router']);
4949

5050
declare module '@uirouter/core/lib/router' {
5151
interface UIRouter {
52-
// tslint:disable-line:no-shadowed-variable
5352
/** @hidden */
5453
stateProvider: StateProvider;
5554
/** @hidden */

‎src/urlRouterProvider.ts‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export interface RawNg1RuleFunction {
3131
* @deprecated
3232
*/
3333
export class UrlRouterProvider {
34-
static injectableHandler(router: UIRouter, handler): UrlRuleHandlerFn {
34+
static injectableHandler(router: UIRouter, handler: IInjectable): UrlRuleHandlerFn {
3535
return (match) => services.$injector.invoke(handler, null, { $match: match, $stateParams: router.globals.params });
3636
}
3737

@@ -164,7 +164,7 @@ export class UrlRouterProvider {
164164
*
165165
* Note: the handler may also invoke arbitrary code, such as `$state.go()`
166166
*/
167-
when(what: RegExp | UrlMatcher | string, handler: string | IInjectable) {
167+
when(what: RegExp | UrlMatcher | string, handler: string | IInjectable): this {
168168
if (isArray(handler) || isFunction(handler)) {
169169
handler = UrlRouterProvider.injectableHandler(this.router, handler);
170170
}
@@ -203,7 +203,7 @@ export class UrlRouterProvider {
203203
* @param defer Indicates whether to defer location change interception.
204204
* Passing no parameter is equivalent to `true`.
205205
*/
206-
deferIntercept(defer?: boolean) {
206+
deferIntercept(defer?: boolean): void {
207207
this.router.urlService.deferIntercept(defer);
208208
}
209209
}

‎tslint.json‎

Lines changed: 0 additions & 59 deletions
This file was deleted.

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /