Skip to content

Commit

Permalink
2024 version
Browse files Browse the repository at this point in the history
  • Loading branch information
fdodino committed Jun 18, 2024
1 parent 0a45c35 commit 34ca9b4
Show file tree
Hide file tree
Showing 59 changed files with 9,698 additions and 6,293 deletions.
13 changes: 6 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,18 @@ jobs:
node-version: [20.x]

steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v4

- name: Cache node modules
uses: actions/cache@v1
uses: actions/cache@v4
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Node ${{ matrix.node-version }}
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}

Expand All @@ -33,8 +33,7 @@ jobs:
npm ci
npm run test:prod
npm run lint
- name: Coverage badge
uses: demyanets/angular-coverage-badges-action@v1
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
coverage-summary-path: coverage/eg-tareas-angular/coverage-summary.json
github_token: ${{ secrets.GITHUB_TOKEN }}
token: ${{ secrets.CODECOV_TOKEN }}
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@
"editor.formatOnSaveMode": "file", // required to format on save
},
"editor.codeActionsOnSave": {
"source.fixAll": true
"source.fixAll": "explicit"
}
}
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,22 @@ Pueden descargar [la implementación Spring Boot del backend](https://github.com

## Componentes adicionales

La instalación de los componentes adicionales luego de hacer `ng new eg-tareas-angular --routing` requiere instalar dependencias adicionales que podrás ver en el `package.json`. El ejemplo trabaja con Bootstrap y [font awesome para Angular](https://github.com/FortAwesome/angular-fontawesome) principalmente.
La instalación de los componentes adicionales luego de hacer `ng new eg-tareas-angular --routing` requiere instalar dependencias adicionales. El ejemplo trabaja con Bootstrap y [font awesome para Angular](https://github.com/FortAwesome/angular-fontawesome) principalmente.

## Agregado en package.json
```bash
npm i @fortawesome/angular-fontawesome @fortawesome/fontawesome-svg-core @fortawesome/free-solid-svg-icons bootstrap
```

## Configuración angular.json

Es necesario incorporar Bootstrap 4 dentro del archivo _angular.json_ de la siguiente manera:
Es necesario incorporar Bootstrap dentro del archivo _angular.json_ de la siguiente manera:

```json
"styles": [
"src/styles.css",
"./node_modules/bootstrap/dist/css/bootstrap.min.css"
],
"scripts": [
"./node_modules/jquery/dist/jquery.slim.min.js",
"./node_modules/bootstrap/dist/js/bootstrap.min.js"
]
```
Expand Down
49 changes: 21 additions & 28 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,29 +11,26 @@
"prefix": "app",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:browser",
"builder": "@angular-devkit/build-angular:application",
"options": {
"allowedCommonJsDependencies": [
"dayjs"
],
"outputPath": "dist/eg-tareas-angular",
"index": "src/index.html",
"main": "src/main.ts",
"browser": "src/main.ts",
"polyfills": [
"zone.js"
],
"tsConfig": "tsconfig.app.json",
"assets": [
"src/favicon.ico",
"src/assets"
{
"glob": "**/*",
"input": "public"
}
],
"styles": [
"src/styles.css",
"./node_modules/bootstrap/dist/css/bootstrap.min.css",
"./node_modules/@angular/cdk/overlay-prebuilt.css"
"./node_modules/bootstrap/dist/css/bootstrap.min.css"
],
"scripts": [
"./node_modules/jquery/dist/jquery.slim.min.js",
"./node_modules/bootstrap/dist/js/bootstrap.min.js"
]
},
Expand All @@ -42,24 +39,21 @@
"budgets": [
{
"type": "initial",
"maximumWarning": "500kb",
"maximumError": "1mb"
"maximumWarning": "500kB",
"maximumError": "1MB"
},
{
"type": "anyComponentStyle",
"maximumWarning": "2kb",
"maximumError": "4kb"
"maximumWarning": "2kB",
"maximumError": "4kB"
}
],
"outputHashing": "all"
},
"development": {
"buildOptimizer": false,
"optimization": false,
"vendorChunk": true,
"extractLicenses": false,
"sourceMap": true,
"namedChunks": true
"sourceMap": true
}
},
"defaultConfiguration": "production"
Expand All @@ -68,19 +62,16 @@
"builder": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
"browserTarget": "eg-tareas-angular:build:production"
"buildTarget": "eg-tareas-angular:build:production"
},
"development": {
"browserTarget": "eg-tareas-angular:build:development"
"buildTarget": "eg-tareas-angular:build:development"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "eg-tareas-angular:build"
}
"builder": "@angular-devkit/build-angular:extract-i18n"
},
"test": {
"builder": "@angular-devkit/build-angular:karma",
Expand All @@ -90,15 +81,17 @@
"zone.js/testing"
],
"tsConfig": "tsconfig.spec.json",
"karmaConfig": "karma.conf.js",
"assets": [
"src/favicon.ico",
"src/assets"
{
"glob": "**/*",
"input": "public"
}
],
"styles": [
"src/styles.css"
],
"scripts": [],
"karmaConfig": "karma.conf.js"
"scripts": []
}
}
}
Expand Down
6 changes: 0 additions & 6 deletions badges/eg-tareas-angular/.gitignore

This file was deleted.

1 change: 0 additions & 1 deletion badges/eg-tareas-angular/coverage-branches.svg

This file was deleted.

1 change: 0 additions & 1 deletion badges/eg-tareas-angular/coverage-functions.svg

This file was deleted.

1 change: 0 additions & 1 deletion badges/eg-tareas-angular/coverage-lines.svg

This file was deleted.

1 change: 0 additions & 1 deletion badges/eg-tareas-angular/coverage-statements.svg

This file was deleted.

1 change: 0 additions & 1 deletion badges/eg-tareas-angular/coverage.svg

This file was deleted.

7 changes: 3 additions & 4 deletions karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,11 @@ module.exports = function (config) {
subdir: '.',
reporters: [
{ type: 'html' },
{ type: 'text-summary' },
{ type: 'json-summary' }
{ type: 'lcov' }
]
},
reporters: ['progress', 'kjhtml'],
browsers: ['Chrome'],
restartOnFileChange: true
});
};
})
}
Loading

0 comments on commit 34ca9b4

Please sign in to comment.