Skip to content

Commit

Permalink
chore/update v10 (blove#2)
Browse files Browse the repository at this point in the history
* chore: update to v10
* chore: update material
* chore: update jest
* chore: specify lts node of 12.13.0 in .nvmrc
* chore: prettier config
  • Loading branch information
blove committed Oct 31, 2020
1 parent 59dcde2 commit a0ea96f
Show file tree
Hide file tree
Showing 11 changed files with 7,113 additions and 6,884 deletions.
File renamed without changes.
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
12.13.0
2 changes: 1 addition & 1 deletion e2e/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"compilerOptions": {
"outDir": "../out-tsc/e2e",
"module": "commonjs",
"target": "es5",
"target": "es2018",
"types": [
"jasmine",
"jasminewd2",
Expand Down
13,779 changes: 6,959 additions & 6,820 deletions package-lock.json

Large diffs are not rendered by default.

62 changes: 33 additions & 29 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,49 +15,54 @@
"e2e": "ng e2e"
},
"private": true,
"engines": {
"node": ">=10.9.0 <13.0.0",
"yarn": ">=1.22.4 <2"
},
"dependencies": {
"@angular/animations": "~9.0.5",
"@angular/cdk": "^9.1.1",
"@angular/common": "~9.0.5",
"@angular/compiler": "~9.0.5",
"@angular/core": "~9.0.5",
"@angular/forms": "~9.0.5",
"@angular/material": "^9.1.1",
"@angular/platform-browser": "~9.0.5",
"@angular/platform-browser-dynamic": "~9.0.5",
"@angular/router": "~9.0.5",
"@angular/animations": "~10.2.1",
"@angular/cdk": "^10.2.6",
"@angular/common": "~10.2.1",
"@angular/compiler": "~10.2.1",
"@angular/core": "~10.2.1",
"@angular/forms": "~10.2.1",
"@angular/material": "^10.2.6",
"@angular/platform-browser": "~10.2.1",
"@angular/platform-browser-dynamic": "~10.2.1",
"@angular/router": "~10.2.1",
"concurrently": "^5.1.0",
"json-server": "^0.16.1",
"rxjs": "~6.5.4",
"tslib": "^1.10.0",
"zone.js": "~0.10.2"
"tslib": "^2.0.0",
"zone.js": "~0.10.3"
},
"devDependencies": {
"@angular-devkit/build-angular": "~0.900.5",
"@angular/cli": "~9.0.5",
"@angular/compiler-cli": "~9.0.5",
"@angular/language-service": "~9.0.5",
"@angular-devkit/build-angular": "~0.1002.0",
"@angular/cli": "~10.2.0",
"@angular/compiler-cli": "~10.2.1",
"@angular/language-service": "~10.2.1",
"@types/jasmine": "~3.5.0",
"@types/jasminewd2": "~2.0.3",
"@types/jest": "^25.1.4",
"@types/jest": "^26.0.15",
"@types/node": "^12.11.1",
"codelyzer": "^5.1.2",
"faker": "^4.1.0",
"husky": "^4.2.3",
"jasmine-core": "~3.5.0",
"jasmine-spec-reporter": "~4.2.1",
"jest": "^25.1.0",
"jest-preset-angular": "^8.0.0",
"karma": "~4.3.0",
"jasmine-spec-reporter": "~5.0.0",
"jest": "^26.6.1",
"jest-preset-angular": "^8.3.2",
"karma": "~5.0.0",
"karma-chrome-launcher": "~3.1.0",
"karma-coverage-istanbul-reporter": "~2.1.0",
"karma-jasmine": "~2.0.1",
"karma-jasmine-html-reporter": "^1.4.2",
"karma-coverage-istanbul-reporter": "~3.0.2",
"karma-jasmine": "~4.0.0",
"karma-jasmine-html-reporter": "^1.5.0",
"lint-staged": "^10.5.1",
"prettier": "^1.19.1",
"protractor": "~5.4.3",
"protractor": "~7.0.0",
"ts-node": "~8.3.0",
"tslint": "~5.18.0",
"typescript": "~3.7.5"
"tslint": "~6.1.0",
"typescript": "~4.0.5"
},
"husky": {
"hooks": {
Expand All @@ -77,8 +82,7 @@
},
"lint-staged": {
"*.{js,json,css,md,ts,html,component.html}": [
"prettier --config ./prettier.config.js --write",
"git add"
"prettier --config ./prettier.config.js --write"
]
}
}
16 changes: 16 additions & 0 deletions prettier.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
module.exports = {
printWidth: 100,
tabWidth: 2,
useTabs: false,
semi: true,
singleQuote: true,
trailingComma: 'none',
bracketSpacing: true,
jsxBracketSameLine: false,
arrowParens: 'avoid',
rangeStart: 0,
rangeEnd: Infinity,
requirePragma: false,
insertPragma: false,
proseWrap: 'preserve'
};
24 changes: 13 additions & 11 deletions src/app/app.component.spec.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
import { TestBed, async } from '@angular/core/testing';
import { RouterTestingModule } from '@angular/router/testing';
import { TestBed, waitForAsync } from "@angular/core/testing";
import { RouterTestingModule } from "@angular/router/testing";

import { AppComponent } from './app.component';
import { AppComponent } from "./app.component";

describe('AppComponent', () => {
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [RouterTestingModule],
declarations: [AppComponent],
}).compileComponents();
}));
describe("AppComponent", () => {
beforeEach(
waitForAsync(() => {
TestBed.configureTestingModule({
imports: [RouterTestingModule],
declarations: [AppComponent]
}).compileComponents();
})
);

it('should create the app', () => {
it("should create the app", () => {
const fixture = TestBed.createComponent(AppComponent);
const app = fixture.componentInstance;
expect(app).toBeTruthy();
Expand Down
26 changes: 14 additions & 12 deletions src/app/core/components/shell/shell.component.spec.ts
Original file line number Diff line number Diff line change
@@ -1,27 +1,29 @@
import { ComponentFixture, TestBed, async } from '@angular/core/testing';
import { RouterTestingModule } from '@angular/router/testing';
import { ComponentFixture, TestBed, waitForAsync } from "@angular/core/testing";
import { RouterTestingModule } from "@angular/router/testing";

import { MaterialModule } from '../../../material';
import { ShellComponent } from './shell.component';
import { MaterialModule } from "../../../material";
import { ShellComponent } from "./shell.component";

describe('ShellComponent', () => {
describe("ShellComponent", () => {
let component: ShellComponent;
let fixture: ComponentFixture<ShellComponent>;

beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ShellComponent],
imports: [MaterialModule, RouterTestingModule],
}).compileComponents();
}));
beforeEach(
waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [ShellComponent],
imports: [MaterialModule, RouterTestingModule]
}).compileComponents();
})
);

beforeEach(() => {
fixture = TestBed.createComponent(ShellComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});

it('should create', () => {
it("should create", () => {
expect(component).toBeTruthy();
});
});
19 changes: 10 additions & 9 deletions src/app/features/home/components/index/index.component.spec.ts
Original file line number Diff line number Diff line change
@@ -1,25 +1,26 @@
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { ComponentFixture, TestBed, waitForAsync } from "@angular/core/testing";

import { IndexComponent } from './index.component';
import { IndexComponent } from "./index.component";

describe('IndexComponent', () => {
describe("IndexComponent", () => {
let component: IndexComponent;
let fixture: ComponentFixture<IndexComponent>;

beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ IndexComponent ]
beforeEach(
waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [IndexComponent]
}).compileComponents();
})
.compileComponents();
}));
);

beforeEach(() => {
fixture = TestBed.createComponent(IndexComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});

it('should create', () => {
it("should create", () => {
expect(component).toBeTruthy();
});
});
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"declaration": false,
"downlevelIteration": true,
"experimentalDecorators": true,
"module": "esnext",
"module": "es2020",
"moduleResolution": "node",
"importHelpers": true,
"target": "es2015",
Expand Down
66 changes: 65 additions & 1 deletion tslint.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,21 @@
{
"extends": "tslint:recommended",
"rules": {
"align": {
"options": [
"parameters",
"statements"
]
},
"array-type": false,
"arrow-parens": false,
"arrow-return-shorthand": true,
"deprecation": {
"severity": "warning"
},
"component-class-suffix": true,
"contextual-lifecycle": true,
"curly": true,
"directive-class-suffix": true,
"directive-selector": [
true,
Expand All @@ -21,10 +29,17 @@
"app",
"kebab-case"
],
"eofline": true,
"import-blacklist": [
true,
"rxjs/Rx"
],
"import-spacing": true,
"indent": {
"options": [
"spaces"
]
},
"interface-name": false,
"max-classes-per-file": false,
"max-line-length": [
Expand Down Expand Up @@ -79,11 +94,60 @@
"no-output-native": true,
"no-output-on-prefix": true,
"no-output-rename": true,
"semicolon": {
"options": [
"always"
]
},
"space-before-function-paren": {
"options": {
"anonymous": "never",
"asyncArrow": "always",
"constructor": "never",
"method": "never",
"named": "never"
}
},
"no-outputs-metadata-property": true,
"template-banana-in-box": true,
"template-no-negated-async": true,
"typedef-whitespace": {
"options": [
{
"call-signature": "nospace",
"index-signature": "nospace",
"parameter": "nospace",
"property-declaration": "nospace",
"variable-declaration": "nospace"
},
{
"call-signature": "onespace",
"index-signature": "onespace",
"parameter": "onespace",
"property-declaration": "onespace",
"variable-declaration": "onespace"
}
]
},
"use-lifecycle-interface": true,
"use-pipe-transform-interface": true
"use-pipe-transform-interface": true,
"variable-name": {
"options": [
"ban-keywords",
"check-format",
"allow-pascal-case"
]
},
"whitespace": {
"options": [
"check-branch",
"check-decl",
"check-operator",
"check-separator",
"check-type",
"check-typecast"
]
}
},
"rulesDirectory": [
"codelyzer"
Expand Down

0 comments on commit a0ea96f

Please sign in to comment.