Skip to content

Commit

Permalink
Merge pull request #226 from gisaia/feature/upadteAngular18
Browse files Browse the repository at this point in the history
chore: update to angular 18
  • Loading branch information
QuCMGisaia authored Dec 19, 2024
2 parents 1c9ef31 + 449d50d commit 008d3fd
Show file tree
Hide file tree
Showing 18 changed files with 11,591 additions and 26,474 deletions.
11 changes: 6 additions & 5 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
},
"plugins": [
"@angular-eslint/eslint-plugin",
"@typescript-eslint"
"@typescript-eslint",
"@stylistic"
],
"rules": {
"@angular-eslint/component-class-suffix": "error",
Expand Down Expand Up @@ -49,7 +50,7 @@
"accessibility": "explicit"
}
],
"@typescript-eslint/member-delimiter-style": [
"@stylistic/member-delimiter-style": [
"error",
{
"multiline": {
Expand Down Expand Up @@ -88,18 +89,18 @@
],
"@typescript-eslint/no-unused-expressions": "error",
"@typescript-eslint/prefer-function-type": "error",
"@typescript-eslint/quotes": [
"@stylistic/quotes": [
2,
"single",
{
"avoidEscape": true,
"allowTemplateLiterals": true
}
],
"@typescript-eslint/semi": [
"@stylistic/semi": [
"error"
],
"@typescript-eslint/type-annotation-spacing": "error",
"@stylistic/type-annotation-spacing": "error",
"@typescript-eslint/unified-signatures": "error",
"arrow-body-style": "error",
"brace-style": [
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ jobs:
steps:
- uses: actions/[email protected]

- name: Use Node 16
- name: Use Node 18
uses: actions/setup-node@v4
with:
node-version: 16
node-version: 18

- name: Cache node modules
id: cache-nodemodules
Expand Down
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
### STAGE 1: Build ###

# We label our stage as 'hub'
FROM node:16.19.0 as hub
FROM node:18.20.5 AS hub

COPY package.json package-lock.json ./

## Storing node modules on a separate layer will prevent unnecessary npm installs at each build
RUN export NODE_OPTIONS=--max_old_space_size=8192 && npm install && mkdir /ng-app && cp -R ./node_modules ./ng-app
RUN npm i --ignore-scripts && npm run postinstall && mkdir /ng-app && cp -R ./node_modules ./ng-app

COPY ./scripts/start.sh ./ng-app

Expand All @@ -15,7 +15,7 @@ WORKDIR /ng-app
COPY . .

## Build the angular app in production mode and store the artifacts in dist folder
RUN export NODE_OPTIONS=--max_old_space_size=8192 && $(npm bin)/ng build --configuration production --aot --base-href='$ARLAS_HUB_BASE_HREF/'
RUN npm run build

### STAGE 2: Setup ###

Expand Down
31 changes: 16 additions & 15 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,17 @@
},
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:browser",
"builder": "@angular-devkit/build-angular:application",
"options": {
"outputPath": "dist",
"outputPath": {
"base": "dist",
"browser": ""
},
"index": "src/index.html",
"main": "src/main.ts",
"tsConfig": "src/tsconfig.app.json",
"polyfills": "src/polyfills.ts",
"polyfills": [
"src/polyfills.ts"
],
"assets": [
"src/assets",
"src/settings.yaml",
Expand All @@ -32,7 +36,8 @@
"src/styles/theme.scss",
"src/styles.scss"
],
"scripts": []
"scripts": [],
"browser": "src/main.ts"
},
"configurations": {
"development": {
Expand All @@ -41,8 +46,6 @@
"sourceMap": true,
"namedChunks": true,
"extractLicenses": false,
"vendorChunk": true,
"buildOptimizer": false,
"budgets": []
},
"production": {
Expand All @@ -52,12 +55,10 @@
"namedChunks": false,
"aot": true,
"extractLicenses": true,
"vendorChunk": false,
"buildOptimizer": true,
"fileReplacements": [
{
"src": "src/environments/environment.ts",
"replaceWith": "src/environments/environment.prod.ts"
"replace": "src/environments/environment.ts",
"with": "src/environments/environment.prod.ts"
}
],
"assets": [
Expand All @@ -77,22 +78,22 @@
"serve": {
"builder": "@angular-devkit/build-angular:dev-server",
"options": {
"browserTarget": "arlas-home:build"
"buildTarget": "arlas-home:build"
},
"configurations": {
"development": {
"browserTarget": "arlas-home:build:development"
"buildTarget": "arlas-home:build:development"
},
"production": {
"browserTarget": "arlas-home:build:production"
"buildTarget": "arlas-home:build:production"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "arlas-home:build"
"buildTarget": "arlas-home:build"
}
},
"test": {
Expand Down
2 changes: 1 addition & 1 deletion e2e/tsconfig.e2e.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/e2e",
"baseUrl": "./",
"baseUrl": "src",
"module": "commonjs",
"target": "es5",
"types": [
Expand Down
Loading

0 comments on commit 008d3fd

Please sign in to comment.