Skip to content

Commit

Permalink
chore(deps): fix linting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
kay-schecker committed Oct 9, 2020
1 parent 6044eaf commit ab17605
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
1 change: 1 addition & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
"@typescript-eslint/explicit-member-accessibility": "off",
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/no-parameter-properties": "off",
"@typescript-eslint/explicit-module-boundary-types": "off",
"@nrwl/nx/enforce-module-boundaries": [
"error",
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ describe('VersionManagerController', () => {

describe('the selection is installed and in use', () => {

let choices: Array<{ name: {}, value: () => unknown }>
let choices: Array<{ name: Record<string, unknown>, value: () => unknown }>

beforeEach(async () => {
whatsNextSpy.mockReset()
Expand All @@ -210,7 +210,7 @@ describe('VersionManagerController', () => {

describe('the selection is installed but not in use', () => {

let choices: Array<{ name: {}, value: () => unknown }>
let choices: Array<{ name: Record<string, unknown>, value: () => unknown }>

beforeEach(async () => {
whatsNextSpy.mockReset()
Expand Down Expand Up @@ -238,7 +238,7 @@ describe('VersionManagerController', () => {

describe('the selection is not installed and not in use', () => {

let choices: Array<{ name: {}, value: () => unknown }>
let choices: Array<{ name: Record<string, unknown>, value: () => unknown }>

beforeEach(async () => {
whatsNextSpy.mockReset()
Expand Down
2 changes: 1 addition & 1 deletion apps/generator-cli/src/app/services/generator.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ export class GeneratorService {
}).join('\n'))
}

private buildCommand(cwd: string, specFile: string, params: {}) {
private buildCommand(cwd: string, specFile: string, params: Record<string, unknown>) {
const absoluteSpecPath = path.resolve(cwd, specFile)

const command = Object.entries({
Expand Down
7 changes: 4 additions & 3 deletions apps/generator-cli/src/app/services/ui.service.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// import ora from 'ora'
import {Injectable} from '@nestjs/common';
import {prompt, Separator} from 'inquirer';
import {getTable} from 'console.table'

@Injectable()
export class UIService {
Expand All @@ -9,11 +10,11 @@ export class UIService {
name: string,
message: string,
printColNum?: boolean,
rows: Array<{ row: {}, short: string, value: T }>,
rows: Array<{ row: Record<string, unknown>, short: string, value: T }>,
}): Promise<T> {


const table = require('console.table').getTable(config.rows.map(({row}, index: number) => {
const table = getTable(config.rows.map(({row}, index: number) => {
return config.printColNum === false ? row : ({'#': index + 1, ...row});
}))

Expand All @@ -38,7 +39,7 @@ export class UIService {
public async list<T>(config: {
name: string,
message: string,
choices: Array<{ name: {}, short?: string, value: T }>,
choices: Array<{ name: Record<string, unknown>, short?: string, value: T }>,
}): Promise<T> {

const separatorCount = config
Expand Down

0 comments on commit ab17605

Please sign in to comment.