Skip to content
Snippets Groups Projects
Commit d24b8ee1 authored by bl05b3e's avatar bl05b3e
Browse files

[wip] Migrate to angular 15

parent f7e7643a
Branches
Tags
No related merge requests found
# This file is used by the build system to adjust CSS and JS output to support the specified browsers below.
# For additional information regarding the format and rule options, please see:
# https://github.com/browserslist/browserslist#queries
# For the full list of supported browsers by the Angular framework, please see:
# https://angular.io/guide/browser-support
# You can see what browsers were selected by your queries by running:
# npx browserslist
last 1 Chrome version
last 1 Firefox version
last 2 Edge major versions
last 2 Safari major versions
last 2 iOS major versions
Firefox ESR
not IE 11 # Angular supports IE 11 only as an opt-in. To opt-in, remove the 'not' prefix on this line.
Source diff could not be displayed: it is too large. Options to address this: view the blob.
......@@ -22,13 +22,13 @@
"generate:meta": "ts-node --skip-project node_modules/.bin/polkadot-types-from-chain --package @duniter/core-types/interfaces --output ./src/interfaces --endpoint ./src/interfaces/types.json"
},
"dependencies": {
"@angular/animations": "^14.2.6",
"@angular/common": "^14.2.6",
"@angular/core": "^14.2.6",
"@angular/forms": "^14.2.6",
"@angular/platform-browser": "^14.2.6",
"@angular/platform-browser-dynamic": "^14.2.6",
"@angular/router": "^14.2.6",
"@angular/animations": "^15.0.2",
"@angular/common": "^15.0.2",
"@angular/core": "^15.0.2",
"@angular/forms": "^15.0.2",
"@angular/platform-browser": "^15.0.2",
"@angular/platform-browser-dynamic": "^15.0.2",
"@angular/router": "^15.0.2",
"@capacitor-community/barcode-scanner": "3.0.0",
"@capacitor-community/sqlite": "^4.0.1",
"@capacitor/android": "4.1.0",
......@@ -68,15 +68,15 @@
"ngx-markdown": "^14.0.1",
"ngx-material-timepicker": "5.5.3",
"ngx-quicklink": "^0.3.0",
"@angular-devkit/build-angular": "^14.2.6",
"@angular-devkit/build-angular": "^15.0.2",
"@angular-eslint/builder": "~13.5.0",
"@angular-eslint/eslint-plugin": "~13.5.0",
"@angular-eslint/eslint-plugin-template": "~13.5.0",
"@angular-eslint/template-parser": "~13.5.0",
"@angular/cli": "^14.2.6",
"@angular/compiler": "^14.2.6",
"@angular/compiler-cli": "^14.2.6",
"@angular/language-service": "^14.2.6",
"@angular/cli": "^15.0.2",
"@angular/compiler": "^15.0.2",
"@angular/compiler-cli": "^15.0.2",
"@angular/language-service": "^15.0.2",
"@capacitor/cli": "4.1.0",
"@ionic/cli": "^6.20.1",
"@ionic/angular-toolkit": "^6.1.0",
......
......@@ -7,13 +7,6 @@ import {
platformBrowserDynamicTesting
} from '@angular/platform-browser-dynamic/testing';
declare const require: {
context(path: string, deep?: boolean, filter?: RegExp): {
keys(): string[];
<T>(id: string): T;
};
};
// First, initialize the Angular testing environment.
getTestBed().initTestEnvironment(
BrowserDynamicTestingModule,
......@@ -21,7 +14,3 @@ getTestBed().initTestEnvironment(
teardown: { destroyAfterEach: false }
}
);
// Then we find all the tests.
const context = require.context('./', true, /\.spec\.ts$/);
// And load the modules.
context.keys().map(context);
......@@ -11,40 +11,61 @@
"moduleResolution": "node",
"importHelpers": true,
"incremental": true,
"target": "es2020",
"target": "ES2022",
"module": "es2020",
"lib": ["es2018", "dom"],
"lib": [
"es2020",
"dom"
],
"allowSyntheticDefaultImports": true,
"typeRoots": [
"node_modules/@types"
],
"paths": {
// Project sources
"@app/*": ["src/app/*"],
"@environments/*": ["src/environments/*"],
// Force using the RxJS project's version
"rxjs": ["node_modules/rxjs"],
"rxjs/*": ["node_modules/rxjs/*"],
// Local deps // Package name
"@duniter/core-types/*": ["src/*"],
// here we replace the @polkadot/api augmentation with our own, generated from chain
"@polkadot/api/augment": ["src/interfaces/augment-api.ts"],
// replace the augmented types with our own, as generated from definitions
"@polkadot/types/augment": ["src/interfaces/augment-types.ts"],
"@polkadot/types": ["./node_modules/@polkadot/types"],
// Node JS lib
"crypto": ["node_modules/crypto-browserify"],
"stream": ["node_modules/stream-browserify"],
"assert": ["node_modules/assert"],
"http": ["node_modules/stream-http"],
"https": ["node_modules/https-browserify"],
"os": ["node_modules/os-browserify"]
}
"@app/*": [
"src/app/*"
],
"@environments/*": [
"src/environments/*"
],
"rxjs": [
"node_modules/rxjs"
],
"rxjs/*": [
"node_modules/rxjs/*"
],
"@duniter/core-types/*": [
"src/*"
],
"@polkadot/api/augment": [
"src/interfaces/augment-api.ts"
],
"@polkadot/types/augment": [
"src/interfaces/augment-types.ts"
],
"@polkadot/types": [
"./node_modules/@polkadot/types"
],
"crypto": [
"node_modules/crypto-browserify"
],
"stream": [
"node_modules/stream-browserify"
],
"assert": [
"node_modules/assert"
],
"http": [
"node_modules/stream-http"
],
"https": [
"node_modules/https-browserify"
],
"os": [
"node_modules/os-browserify"
]
},
"useDefineForClassFields": false
},
"angularCompilerOptions": {
"enableI18nLegacyMessageIdFormat": false,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment