Skip to content

Commit ceb3ca7

Browse files
committed
chore: 🤖 update nx
1 parent 64859ec commit ceb3ca7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+8966
-26126
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -42,4 +42,6 @@ Thumbs.db
4242
# Cypress
4343
apps/transloco-playground-e2e/cypress/screenshots/*
4444

45+
.nx/cache
46+
4547
.nx

.prettierignore

+2
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,5 @@
33
/dist
44
/coverage
55
/docs/docs
6+
7+
/.nx/cache

apps/transloco-playground-e2e/project.json

+1-4
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,7 @@
1919
}
2020
},
2121
"lint": {
22-
"executor": "@nx/linter:eslint",
23-
"options": {
24-
"lintFilePatterns": ["apps/transloco-playground-e2e/**/*.{js,ts}"]
25-
},
22+
"executor": "@nx/eslint:lint",
2623
"outputs": ["{options.outputFile}"]
2724
}
2825
},

apps/transloco-playground/project.json

+4-10
Original file line numberDiff line numberDiff line change
@@ -61,28 +61,22 @@
6161
"executor": "@angular-devkit/build-angular:dev-server",
6262
"configurations": {
6363
"production": {
64-
"browserTarget": "transloco-playground:build:production"
64+
"buildTarget": "transloco-playground:build:production"
6565
},
6666
"development": {
67-
"browserTarget": "transloco-playground:build:development"
67+
"buildTarget": "transloco-playground:build:development"
6868
}
6969
},
7070
"defaultConfiguration": "development"
7171
},
7272
"extract-i18n": {
7373
"executor": "@angular-devkit/build-angular:extract-i18n",
7474
"options": {
75-
"browserTarget": "transloco-playground:build"
75+
"buildTarget": "transloco-playground:build"
7676
}
7777
},
7878
"lint": {
79-
"executor": "@nx/linter:eslint",
80-
"options": {
81-
"lintFilePatterns": [
82-
"apps/transloco-playground/src/**/*.ts",
83-
"apps/transloco-playground/src/**/*.html"
84-
]
85-
},
79+
"executor": "@nx/eslint:lint",
8680
"outputs": ["{options.outputFile}"]
8781
},
8882
"test": {

apps/transloco-playground/src/app/lazy-scope-alias/lazy-scope-alias.component.ts

-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import { Component } from '@angular/core';
22

33
import {
44
TranslocoModule,
5-
TRANSLOCO_SCOPE,
65
provideTranslocoScope,
76
} from '@ngneat/transloco';
87

apps/transloco-playground/src/app/lazy-scope-alias/lazy-scope-alias.routes.ts

-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import { Route } from '@angular/router';
22

33
import {
44
provideTranslocoLoadingTpl,
5-
TRANSLOCO_LOADING_TEMPLATE,
65
} from '@ngneat/transloco';
76

87
export const LAZY_SCOPE_ALIAS_ROUTES: Route = {

apps/transloco-playground/src/app/scope-sharing/scope-sharing.routes.ts

-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ import { Route } from '@angular/router';
33
import {
44
provideTranslocoLoadingTpl,
55
provideTranslocoScope,
6-
TRANSLOCO_LOADING_TEMPLATE,
7-
TRANSLOCO_SCOPE,
86
} from '@ngneat/transloco';
97

108
export const SCOPE_SHARING_ROUTES: Route = {

apps/transloco-playground/src/test-setup.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
22

3-
import 'zone.js/dist/zone';
3+
import 'zone.js';
44

5-
import 'zone.js/dist/zone-testing';
5+
import 'zone.js/testing';
66
import { getTestBed } from '@angular/core/testing';
77
import {
88
BrowserDynamicTestingModule,

libs/transloco-locale/project.json

+1-7
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,7 @@
3030
}
3131
},
3232
"lint": {
33-
"executor": "@nx/linter:eslint",
34-
"options": {
35-
"lintFilePatterns": [
36-
"libs/transloco-locale/src/**/*.ts",
37-
"libs/transloco-locale/src/**/*.html"
38-
]
39-
},
33+
"executor": "@nx/eslint:lint",
4034
"outputs": ["{options.outputFile}"]
4135
},
4236
"version": {

libs/transloco-locale/src/lib/pipes/base-locale.pipe.ts

-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import { Subscription } from 'rxjs';
99
import { Locale } from '../../lib/transloco-locale.types';
1010
import { TranslocoLocaleService } from '../transloco-locale.service';
1111

12-
type Deps = [TranslocoLocaleService, ChangeDetectorRef];
1312
@Injectable()
1413
export abstract class BaseLocalePipe implements OnDestroy {
1514
protected localeService = inject(TranslocoLocaleService);

libs/transloco-locale/src/test-setup.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
22

3-
import 'zone.js/dist/zone';
3+
import 'zone.js';
44

5-
import 'zone.js/dist/zone-testing';
5+
import 'zone.js/testing';
66
import { getTestBed } from '@angular/core/testing';
77
import {
88
BrowserDynamicTestingModule,

libs/transloco-messageformat/.eslintrc.json

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
"plugin:@angular-eslint/template/process-inline-templates"
1010
],
1111
"rules": {
12+
"@typescript-eslint/no-explicit-any": "warn",
1213
"@angular-eslint/directive-selector": [
1314
"error",
1415
{

libs/transloco-messageformat/project.json

+1-7
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,7 @@
3030
}
3131
},
3232
"lint": {
33-
"executor": "@nx/linter:eslint",
34-
"options": {
35-
"lintFilePatterns": [
36-
"libs/transloco-messageformat/src/**/*.ts",
37-
"libs/transloco-messageformat/src/**/*.html"
38-
]
39-
},
33+
"executor": "@nx/eslint:lint",
4034
"outputs": ["{options.outputFile}"]
4135
},
4236
"version": {

libs/transloco-messageformat/src/test-setup.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
22

3-
import 'zone.js/dist/zone';
3+
import 'zone.js';
44

5-
import 'zone.js/dist/zone-testing';
5+
import 'zone.js/testing';
66
import { getTestBed } from '@angular/core/testing';
77
import {
88
BrowserDynamicTestingModule,

libs/transloco-optimize/project.json

+1-4
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,7 @@
1515
}
1616
},
1717
"lint": {
18-
"executor": "@nx/linter:eslint",
19-
"options": {
20-
"lintFilePatterns": ["libs/transloco-optimize/**/*.ts"]
21-
},
18+
"executor": "@nx/eslint:lint",
2219
"outputs": ["{options.outputFile}"]
2320
},
2421
"test": {

libs/transloco-optimize/src/lib/transloco-optimize.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import path from 'node:path';
44
import { glob } from 'glob';
55
import { flatten } from 'flat';
66

7-
type Translation = Record<string, any>;
7+
type Translation = Record<string, string>;
88

99
const isWindows = process.platform === "win32";
1010

libs/transloco-optimize/src/test-setup.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
22

3-
import 'zone.js/dist/zone';
3+
import 'zone.js';
44

5-
import 'zone.js/dist/zone-testing';
5+
import 'zone.js/testing';
66
import { getTestBed } from '@angular/core/testing';
77
import {
88
BrowserDynamicTestingModule,

libs/transloco-persist-lang/project.json

+1-7
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,7 @@
3030
}
3131
},
3232
"lint": {
33-
"executor": "@nx/linter:eslint",
34-
"options": {
35-
"lintFilePatterns": [
36-
"libs/transloco-persist-lang/src/**/*.ts",
37-
"libs/transloco-persist-lang/src/**/*.html"
38-
]
39-
},
33+
"executor": "@nx/eslint:lint",
4034
"outputs": ["{options.outputFile}"]
4135
},
4236
"version": {

libs/transloco-persist-lang/src/lib/persist-lang.providers.ts

+2-9
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,14 @@
11
import {
22
APP_INITIALIZER,
33
ClassProvider,
4-
ConstructorProvider,
54
ExistingProvider,
65
FactoryProvider,
76
makeEnvironmentProviders,
8-
Provider,
9-
TypeProvider,
107
ValueProvider,
118
} from '@angular/core';
129

13-
import {
14-
PersistLangConfig,
15-
TRANSLOCO_PERSIST_LANG_CONFIG,
16-
TRANSLOCO_PERSIST_LANG_STORAGE,
17-
} from './persist-lang.config';
18-
import { TranslocoPersistLangService } from './persist-lang.service';
10+
import {PersistLangConfig, TRANSLOCO_PERSIST_LANG_CONFIG, TRANSLOCO_PERSIST_LANG_STORAGE,} from './persist-lang.config';
11+
import {TranslocoPersistLangService} from './persist-lang.service';
1912

2013
// eslint-disable-next-line @typescript-eslint/no-empty-function
2114
function noop() {}

libs/transloco-persist-lang/src/test-setup.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
22

3-
import 'zone.js/dist/zone';
3+
import 'zone.js';
44

5-
import 'zone.js/dist/zone-testing';
5+
import 'zone.js/testing';
66
import { getTestBed } from '@angular/core/testing';
77
import {
88
BrowserDynamicTestingModule,

libs/transloco-persist-translations/.eslintrc.json

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
"plugin:@angular-eslint/template/process-inline-templates"
1010
],
1111
"rules": {
12+
"@typescript-eslint/no-explicit-any": "warn",
1213
"@angular-eslint/directive-selector": [
1314
"error",
1415
{

libs/transloco-persist-translations/project.json

+1-7
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,7 @@
3030
}
3131
},
3232
"lint": {
33-
"executor": "@nx/linter:eslint",
34-
"options": {
35-
"lintFilePatterns": [
36-
"libs/transloco-persist-translations/src/**/*.ts",
37-
"libs/transloco-persist-translations/src/**/*.html"
38-
]
39-
},
33+
"executor": "@nx/eslint:lint",
4034
"outputs": ["{options.outputFile}"]
4135
},
4236
"version": {

libs/transloco-persist-translations/src/lib/transloco-persist-translations.providers.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { makeEnvironmentProviders, Provider } from '@angular/core';
1+
import { makeEnvironmentProviders } from '@angular/core';
22
import { TRANSLOCO_LOADER } from '@ngneat/transloco';
33

44
import { TranslocoPersistTranslations } from './transloco-persist-translations.service';

libs/transloco-persist-translations/src/test-setup.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
22

3-
import 'zone.js/dist/zone';
3+
import 'zone.js';
44

5-
import 'zone.js/dist/zone-testing';
5+
import 'zone.js/testing';
66
import { getTestBed } from '@angular/core/testing';
77
import {
88
BrowserDynamicTestingModule,

libs/transloco-preload-langs/project.json

+1-7
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,7 @@
3030
}
3131
},
3232
"lint": {
33-
"executor": "@nx/linter:eslint",
34-
"options": {
35-
"lintFilePatterns": [
36-
"libs/transloco-preload-langs/src/**/*.ts",
37-
"libs/transloco-preload-langs/src/**/*.html"
38-
]
39-
},
33+
"executor": "@nx/eslint:lint",
4034
"outputs": ["{options.outputFile}"]
4135
},
4236
"version": {

libs/transloco-preload-langs/src/test-setup.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
22

3-
import 'zone.js/dist/zone';
3+
import 'zone.js';
44

5-
import 'zone.js/dist/zone-testing';
5+
import 'zone.js/testing';
66
import { getTestBed } from '@angular/core/testing';
77
import {
88
BrowserDynamicTestingModule,

libs/transloco-schematics/.eslintrc.json

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
{
1010
"files": ["*.ts", "*.tsx"],
1111
"rules": {
12+
"@typescript-eslint/no-explicit-any": "warn",
1213
"@typescript-eslint/ban-ts-comment": "off"
1314
}
1415
},

libs/transloco-schematics/jest.config.ts

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1+
import type {Config} from 'jest';
2+
13
export default {
24
displayName: 'transloco-schematics',
3-
5+
testEnvironment: 'node',
46
globals: {},
57
transform: {
68
'^.+\\.[tj]sx?$': [
@@ -13,4 +15,4 @@ export default {
1315
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
1416
coverageDirectory: '../../coverage/libs/transloco-schematics',
1517
preset: '../../jest.preset.js',
16-
};
18+
} as Config;

libs/transloco-schematics/project.json

+2-6
Original file line numberDiff line numberDiff line change
@@ -26,18 +26,14 @@
2626
}
2727
},
2828
"lint": {
29-
"executor": "@nx/linter:eslint",
30-
"options": {
31-
"lintFilePatterns": ["libs/transloco-schematics/**/*.ts"]
32-
},
29+
"executor": "@nx/eslint:lint",
3330
"outputs": ["{options.outputFile}"]
3431
},
3532
"test": {
3633
"executor": "@nx/jest:jest",
3734
"outputs": ["{workspaceRoot}/coverage/libs/transloco-schematics"],
3835
"options": {
39-
"jestConfig": "libs/transloco-schematics/jest.config.ts",
40-
"passWithNoTests": true
36+
"jestConfig": "libs/transloco-schematics/jest.config.ts"
4137
}
4238
}
4339
},

libs/transloco-schematics/src/split/index.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import { split } from '@angular-devkit/core';
21
import { Rule, Tree } from '@angular-devkit/schematics';
32

43
import { TranslationFileFormat } from '../types';
@@ -14,7 +13,7 @@ import {
1413

1514
import { SchemaOptions } from './schema';
1615

17-
type Parser = (content: string) => any;
16+
type Parser = (content: string) => unknown;
1817

1918
function reduceTranslations(
2019
host: Tree,

0 commit comments

Comments
 (0)