Skip to content

Commit

Permalink
chore(ngx-codejar): update nx and Angular to 16
Browse files Browse the repository at this point in the history
  • Loading branch information
julianpoemp committed Mar 9, 2024
1 parent e782949 commit b6992ba
Show file tree
Hide file tree
Showing 39 changed files with 9,404 additions and 24,922 deletions.
8 changes: 4 additions & 4 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"root": true,
"ignorePatterns": ["**/*"],
"plugins": ["@nrwl/nx"],
"plugins": ["@nx"],
"overrides": [
{
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
"rules": {
"@nrwl/nx/enforce-module-boundaries": [
"@nx/enforce-module-boundaries": [
"error",
{
"enforceBuildableLibDependency": true,
Expand All @@ -23,12 +23,12 @@
},
{
"files": ["*.ts", "*.tsx"],
"extends": ["plugin:@nrwl/nx/typescript"],
"extends": ["plugin:@nx/typescript"],
"rules": {}
},
{
"files": ["*.js", "*.jsx"],
"extends": ["plugin:@nrwl/nx/javascript"],
"extends": ["plugin:@nx/javascript"],
"rules": {}
},
{
Expand Down
Empty file removed apps/.gitkeep
Empty file.
10 changes: 0 additions & 10 deletions apps/demo-e2e/.eslintrc.json

This file was deleted.

6 changes: 0 additions & 6 deletions apps/demo-e2e/cypress.config.ts

This file was deleted.

33 changes: 0 additions & 33 deletions apps/demo-e2e/project.json

This file was deleted.

13 changes: 0 additions & 13 deletions apps/demo-e2e/src/e2e/app.cy.ts

This file was deleted.

4 changes: 0 additions & 4 deletions apps/demo-e2e/src/fixtures/example.json

This file was deleted.

1 change: 0 additions & 1 deletion apps/demo-e2e/src/support/app.po.ts

This file was deleted.

33 changes: 0 additions & 33 deletions apps/demo-e2e/src/support/commands.ts

This file was deleted.

17 changes: 0 additions & 17 deletions apps/demo-e2e/src/support/e2e.ts

This file was deleted.

16 changes: 0 additions & 16 deletions apps/demo-e2e/tsconfig.json

This file was deleted.

16 changes: 8 additions & 8 deletions apps/demo/.eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,32 +4,32 @@
"overrides": [
{
"files": ["*.ts"],
"extends": [
"plugin:@nx/angular",
"plugin:@angular-eslint/template/process-inline-templates"
],
"rules": {
"@angular-eslint/directive-selector": [
"error",
{
"type": "attribute",
"prefix": "ngxCodejarNew",
"prefix": "ngxCodejar2",
"style": "camelCase"
}
],
"@angular-eslint/component-selector": [
"error",
{
"type": "element",
"prefix": "ngx-codejar-new",
"prefix": "ngx-codejar",
"style": "kebab-case"
}
]
},
"extends": [
"plugin:@nrwl/nx/angular",
"plugin:@angular-eslint/template/process-inline-templates"
]
}
},
{
"files": ["*.html"],
"extends": ["plugin:@nrwl/nx/angular-template"],
"extends": ["plugin:@nx/angular-template"],
"rules": {}
}
]
Expand Down
24 changes: 12 additions & 12 deletions apps/demo/jest.config.ts
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
/* eslint-disable */
export default {
displayName: "demo",
preset: "../../jest.preset.js",
setupFilesAfterEnv: ["<rootDir>/src/test-setup.ts"],
coverageDirectory: "../../coverage/apps/demo",
displayName: 'demo',
preset: '../../jest.preset.js',
setupFilesAfterEnv: ['<rootDir>/src/test-setup.ts'],
coverageDirectory: '../../coverage/apps/demo',
transform: {
"^.+\\.(ts|mjs|js|html)$": [
"jest-preset-angular",
'^.+\\.(ts|mjs|js|html)$': [
'jest-preset-angular',
{
tsconfig: "<rootDir>/tsconfig.spec.json",
stringifyContentPathRegex: "\\.(html|svg)$",
tsconfig: '<rootDir>/tsconfig.spec.json',
stringifyContentPathRegex: '\\.(html|svg)$',
},
],
},
transformIgnorePatterns: ["node_modules/(?!.*\\.mjs$)"],
transformIgnorePatterns: ['node_modules/(?!.*\\.mjs$)'],
snapshotSerializers: [
"jest-preset-angular/build/serializers/no-ng-attributes",
"jest-preset-angular/build/serializers/ng-snapshot",
"jest-preset-angular/build/serializers/html-comment",
'jest-preset-angular/build/serializers/no-ng-attributes',
'jest-preset-angular/build/serializers/ng-snapshot',
'jest-preset-angular/build/serializers/html-comment',
],
};
48 changes: 29 additions & 19 deletions apps/demo/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,32 @@
"name": "demo",
"$schema": "../../node_modules/nx/schemas/project-schema.json",
"projectType": "application",
"prefix": "ngx-codejar-new",
"prefix": "ngx-codejar",
"sourceRoot": "apps/demo/src",
"tags": [],
"targets": {
"build": {
"executor": "@angular-devkit/build-angular:browser",
"outputs": ["{options.outputPath}"],
"outputs": [
"{options.outputPath}"
],
"options": {
"outputPath": "dist/apps/demo",
"index": "apps/demo/src/index.html",
"main": "apps/demo/src/main.ts",
"polyfills": ["zone.js"],
"polyfills": [
"zone.js"
],
"tsConfig": "apps/demo/tsconfig.app.json",
"assets": ["apps/demo/src/favicon.ico", "apps/demo/src/assets"],
"styles": ["node_modules/highlight.js/styles/github-dark.css",
"node_modules/prismjs/themes/prism-dark.css","apps/demo/src/styles.scss",
"node_modules/codejar-linenumbers/es/codejar-linenumbers.css"
"assets": [
"apps/demo/src/favicon.ico",
"apps/demo/src/assets"
],
"styles": [
"node_modules/highlight.js/styles/github-dark.css",
"node_modules/prismjs/themes/prism-dark.css",
"node_modules/codejar-linenumbers/es/codejar-linenumbers.css",
"apps/demo/src/styles.scss"
],
"scripts": []
},
Expand All @@ -28,7 +37,7 @@
{
"type": "initial",
"maximumWarning": "500kb",
"maximumError": "2mb"
"maximumError": "1mb"
},
{
"type": "anyComponentStyle",
Expand Down Expand Up @@ -68,15 +77,22 @@
}
},
"lint": {
"executor": "@nrwl/linter:eslint",
"outputs": ["{options.outputFile}"],
"executor": "@nx/linter:eslint",
"outputs": [
"{options.outputFile}"
],
"options": {
"lintFilePatterns": ["apps/demo/**/*.ts", "apps/demo/**/*.html"]
"lintFilePatterns": [
"apps/demo/**/*.ts",
"apps/demo/**/*.html"
]
}
},
"test": {
"executor": "@nrwl/jest:jest",
"outputs": ["{workspaceRoot}/coverage/{projectRoot}"],
"executor": "@nx/jest:jest",
"outputs": [
"{workspaceRoot}/coverage/{projectRoot}"
],
"options": {
"jestConfig": "apps/demo/jest.config.ts",
"passWithNoTests": true
Expand All @@ -87,12 +103,6 @@
"codeCoverage": true
}
}
},
"serve-static": {
"executor": "@nrwl/web:file-server",
"options": {
"buildTarget": "demo:build"
}
}
}
}
File renamed without changes.
31 changes: 0 additions & 31 deletions apps/demo/src/app/app.component.spec.ts

This file was deleted.

8 changes: 5 additions & 3 deletions apps/demo/src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@ import {Component} from '@angular/core';
import hljs from 'highlight.js';
import * as Prism from 'prismjs';
import 'prismjs/components/prism-typescript';
import {CodeJarContainer} from 'ngx-codejar';
import {CodeJarContainer, NgxCodeJarComponent} from 'ngx-codejar';

@Component({
selector: 'app-root',
standalone: true,
imports: [NgxCodeJarComponent],
selector: 'ngx-codejar-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
styleUrls: ['./app.component.scss'],
})
export class AppComponent {
title = 'demo';
Expand Down
5 changes: 5 additions & 0 deletions apps/demo/src/app/app.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { ApplicationConfig } from '@angular/core';

export const appConfig: ApplicationConfig = {
providers: [],
};
Loading

0 comments on commit b6992ba

Please sign in to comment.