Skip to content

Commit 612a47d

Browse files
committedMar 9, 2021
initial commit
0 parents  commit 612a47d

31 files changed

+16331
-0
lines changed
 

‎.browserslistrc

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# This file is used by the build system to adjust CSS and JS output to support the specified browsers below.
2+
# For additional information regarding the format and rule options, please see:
3+
# https://github.com/browserslist/browserslist#queries
4+
5+
# For the full list of supported browsers by the Angular framework, please see:
6+
# https://angular.io/guide/browser-support
7+
8+
# You can see what browsers were selected by your queries by running:
9+
# npx browserslist
10+
11+
last 1 Chrome version
12+
last 1 Firefox version
13+
last 2 Edge major versions
14+
last 2 Safari major versions
15+
last 2 iOS major versions
16+
Firefox ESR
17+
not IE 11 # Angular supports IE 11 only as an opt-in. To opt-in, remove the 'not' prefix on this line.

‎.editorconfig

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Editor configuration, see https://editorconfig.org
2+
root = true
3+
4+
[*]
5+
charset = utf-8
6+
indent_style = space
7+
indent_size = 2
8+
insert_final_newline = true
9+
trim_trailing_whitespace = true
10+
11+
[*.ts]
12+
quote_type = single
13+
14+
[*.md]
15+
max_line_length = off
16+
trim_trailing_whitespace = false

‎.gitignore

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# See http://help.github.com/ignore-files/ for more about ignoring files.
2+
3+
# compiled output
4+
/dist
5+
/tmp
6+
/out-tsc
7+
# Only exists if Bazel was run
8+
/bazel-out
9+
10+
# dependencies
11+
/node_modules
12+
13+
# profiling files
14+
chrome-profiler-events*.json
15+
speed-measure-plugin*.json
16+
17+
# IDEs and editors
18+
/.idea
19+
.project
20+
.classpath
21+
.c9/
22+
*.launch
23+
.settings/
24+
*.sublime-workspace
25+
26+
# IDE - VSCode
27+
.vscode/*
28+
!.vscode/settings.json
29+
!.vscode/tasks.json
30+
!.vscode/launch.json
31+
!.vscode/extensions.json
32+
.history/*
33+
34+
# misc
35+
/.sass-cache
36+
/connect.lock
37+
/coverage
38+
/libpeerconnection.log
39+
npm-debug.log
40+
yarn-error.log
41+
testem.log
42+
/typings
43+
44+
# System Files
45+
.DS_Store
46+
Thumbs.db

‎README.md

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# AngularResponsiveSidebar
2+
3+
This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 11.2.0.
4+
5+
## Development server
6+
7+
Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.
8+
9+
## Code scaffolding
10+
11+
Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.
12+
13+
## Build
14+
15+
Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `--prod` flag for a production build.
16+
17+
## Running unit tests
18+
19+
Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).
20+
21+
## Running end-to-end tests
22+
23+
Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).
24+
25+
## Further help
26+
27+
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.

‎angular.json

+131
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,131 @@
1+
{
2+
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
3+
"version": 1,
4+
"newProjectRoot": "projects",
5+
"projects": {
6+
"angular-responsive-sidebar": {
7+
"projectType": "application",
8+
"schematics": {
9+
"@schematics/angular:component": {
10+
"style": "scss"
11+
},
12+
"@schematics/angular:application": {
13+
"strict": true
14+
}
15+
},
16+
"root": "",
17+
"sourceRoot": "src",
18+
"prefix": "app",
19+
"architect": {
20+
"build": {
21+
"builder": "@angular-devkit/build-angular:browser",
22+
"options": {
23+
"outputPath": "dist/angular-responsive-sidebar",
24+
"index": "src/index.html",
25+
"main": "src/main.ts",
26+
"polyfills": "src/polyfills.ts",
27+
"tsConfig": "tsconfig.app.json",
28+
"aot": true,
29+
"assets": [
30+
"src/favicon.ico",
31+
"src/assets"
32+
],
33+
"styles": [
34+
"src/styles.scss"
35+
],
36+
"scripts": []
37+
},
38+
"configurations": {
39+
"production": {
40+
"fileReplacements": [
41+
{
42+
"replace": "src/environments/environment.ts",
43+
"with": "src/environments/environment.prod.ts"
44+
}
45+
],
46+
"optimization": true,
47+
"outputHashing": "all",
48+
"sourceMap": false,
49+
"namedChunks": false,
50+
"extractLicenses": true,
51+
"vendorChunk": false,
52+
"buildOptimizer": true,
53+
"budgets": [
54+
{
55+
"type": "initial",
56+
"maximumWarning": "500kb",
57+
"maximumError": "1mb"
58+
},
59+
{
60+
"type": "anyComponentStyle",
61+
"maximumWarning": "2kb",
62+
"maximumError": "4kb"
63+
}
64+
]
65+
}
66+
}
67+
},
68+
"serve": {
69+
"builder": "@angular-devkit/build-angular:dev-server",
70+
"options": {
71+
"browserTarget": "angular-responsive-sidebar:build"
72+
},
73+
"configurations": {
74+
"production": {
75+
"browserTarget": "angular-responsive-sidebar:build:production"
76+
}
77+
}
78+
},
79+
"extract-i18n": {
80+
"builder": "@angular-devkit/build-angular:extract-i18n",
81+
"options": {
82+
"browserTarget": "angular-responsive-sidebar:build"
83+
}
84+
},
85+
"test": {
86+
"builder": "@angular-devkit/build-angular:karma",
87+
"options": {
88+
"main": "src/test.ts",
89+
"polyfills": "src/polyfills.ts",
90+
"tsConfig": "tsconfig.spec.json",
91+
"karmaConfig": "karma.conf.js",
92+
"assets": [
93+
"src/favicon.ico",
94+
"src/assets"
95+
],
96+
"styles": [
97+
"src/styles.scss"
98+
],
99+
"scripts": []
100+
}
101+
},
102+
"lint": {
103+
"builder": "@angular-devkit/build-angular:tslint",
104+
"options": {
105+
"tsConfig": [
106+
"tsconfig.app.json",
107+
"tsconfig.spec.json",
108+
"e2e/tsconfig.json"
109+
],
110+
"exclude": [
111+
"**/node_modules/**"
112+
]
113+
}
114+
},
115+
"e2e": {
116+
"builder": "@angular-devkit/build-angular:protractor",
117+
"options": {
118+
"protractorConfig": "e2e/protractor.conf.js",
119+
"devServerTarget": "angular-responsive-sidebar:serve"
120+
},
121+
"configurations": {
122+
"production": {
123+
"devServerTarget": "angular-responsive-sidebar:serve:production"
124+
}
125+
}
126+
}
127+
}
128+
}
129+
},
130+
"defaultProject": "angular-responsive-sidebar"
131+
}

‎e2e/protractor.conf.js

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
// @ts-check
2+
// Protractor configuration file, see link for more information
3+
// https://github.com/angular/protractor/blob/master/lib/config.ts
4+
5+
const { SpecReporter, StacktraceOption } = require('jasmine-spec-reporter');
6+
7+
/**
8+
* @type { import("protractor").Config }
9+
*/
10+
exports.config = {
11+
allScriptsTimeout: 11000,
12+
specs: [
13+
'./src/**/*.e2e-spec.ts'
14+
],
15+
capabilities: {
16+
browserName: 'chrome'
17+
},
18+
directConnect: true,
19+
SELENIUM_PROMISE_MANAGER: false,
20+
baseUrl: 'http://localhost:4200/',
21+
framework: 'jasmine',
22+
jasmineNodeOpts: {
23+
showColors: true,
24+
defaultTimeoutInterval: 30000,
25+
print: function() {}
26+
},
27+
onPrepare() {
28+
require('ts-node').register({
29+
project: require('path').join(__dirname, './tsconfig.json')
30+
});
31+
jasmine.getEnv().addReporter(new SpecReporter({
32+
spec: {
33+
displayStacktrace: StacktraceOption.PRETTY
34+
}
35+
}));
36+
}
37+
};

‎e2e/src/app.e2e-spec.ts

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import { browser, logging } from 'protractor';
2+
import { AppPage } from './app.po';
3+
4+
describe('workspace-project App', () => {
5+
let page: AppPage;
6+
7+
beforeEach(() => {
8+
page = new AppPage();
9+
});
10+
11+
it('should display welcome message', async () => {
12+
await page.navigateTo();
13+
expect(await page.getTitleText()).toEqual('angular-responsive-sidebar app is running!');
14+
});
15+
16+
afterEach(async () => {
17+
// Assert that there are no errors emitted from the browser
18+
const logs = await browser.manage().logs().get(logging.Type.BROWSER);
19+
expect(logs).not.toContain(jasmine.objectContaining({
20+
level: logging.Level.SEVERE,
21+
} as logging.Entry));
22+
});
23+
});

‎e2e/src/app.po.ts

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { browser, by, element } from 'protractor';
2+
3+
export class AppPage {
4+
async navigateTo(): Promise<unknown> {
5+
return browser.get(browser.baseUrl);
6+
}
7+
8+
async getTitleText(): Promise<string> {
9+
return element(by.css('app-root .content span')).getText();
10+
}
11+
}

‎e2e/tsconfig.json

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/* To learn more about this file see: https://angular.io/config/tsconfig. */
2+
{
3+
"extends": "../tsconfig.json",
4+
"compilerOptions": {
5+
"outDir": "../out-tsc/e2e",
6+
"module": "commonjs",
7+
"target": "es2018",
8+
"types": [
9+
"jasmine",
10+
"node"
11+
]
12+
}
13+
}

‎karma.conf.js

+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
// Karma configuration file, see link for more information
2+
// https://karma-runner.github.io/1.0/config/configuration-file.html
3+
4+
module.exports = function (config) {
5+
config.set({
6+
basePath: '',
7+
frameworks: ['jasmine', '@angular-devkit/build-angular'],
8+
plugins: [
9+
require('karma-jasmine'),
10+
require('karma-chrome-launcher'),
11+
require('karma-jasmine-html-reporter'),
12+
require('karma-coverage'),
13+
require('@angular-devkit/build-angular/plugins/karma')
14+
],
15+
client: {
16+
jasmine: {
17+
// you can add configuration options for Jasmine here
18+
// the possible options are listed at https://jasmine.github.io/api/edge/Configuration.html
19+
// for example, you can disable the random execution with `random: false`
20+
// or set a specific seed with `seed: 4321`
21+
},
22+
clearContext: false // leave Jasmine Spec Runner output visible in browser
23+
},
24+
jasmineHtmlReporter: {
25+
suppressAll: true // removes the duplicated traces
26+
},
27+
coverageReporter: {
28+
dir: require('path').join(__dirname, './coverage/angular-responsive-sidebar'),
29+
subdir: '.',
30+
reporters: [
31+
{ type: 'html' },
32+
{ type: 'text-summary' }
33+
]
34+
},
35+
reporters: ['progress', 'kjhtml'],
36+
port: 9876,
37+
colors: true,
38+
logLevel: config.LOG_INFO,
39+
autoWatch: true,
40+
browsers: ['Chrome'],
41+
singleRun: false,
42+
restartOnFileChange: true
43+
});
44+
};

‎package-lock.json

+14,964
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎package.json

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
{
2+
"name": "angular-responsive-sidebar",
3+
"version": "0.0.0",
4+
"scripts": {
5+
"ng": "ng",
6+
"start": "ng serve",
7+
"build": "ng build",
8+
"test": "ng test",
9+
"lint": "ng lint",
10+
"e2e": "ng e2e"
11+
},
12+
"private": true,
13+
"dependencies": {
14+
"@angular/animations": "~11.2.0",
15+
"@angular/common": "~11.2.0",
16+
"@angular/compiler": "~11.2.0",
17+
"@angular/core": "~11.2.0",
18+
"@angular/forms": "~11.2.0",
19+
"@angular/platform-browser": "~11.2.0",
20+
"@angular/platform-browser-dynamic": "~11.2.0",
21+
"@angular/router": "~11.2.0",
22+
"rxjs": "~6.6.0",
23+
"tslib": "^2.0.0",
24+
"zone.js": "~0.11.3"
25+
},
26+
"devDependencies": {
27+
"@angular-devkit/build-angular": "~0.1102.0",
28+
"@angular/cli": "~11.2.0",
29+
"@angular/compiler-cli": "~11.2.0",
30+
"@types/jasmine": "~3.6.0",
31+
"@types/node": "^12.11.1",
32+
"codelyzer": "^6.0.0",
33+
"jasmine-core": "~3.6.0",
34+
"jasmine-spec-reporter": "~5.0.0",
35+
"karma": "~6.1.0",
36+
"karma-chrome-launcher": "~3.1.0",
37+
"karma-coverage": "~2.0.3",
38+
"karma-jasmine": "~4.0.0",
39+
"karma-jasmine-html-reporter": "^1.5.0",
40+
"protractor": "~7.0.0",
41+
"ts-node": "~8.3.0",
42+
"tslint": "~6.1.0",
43+
"typescript": "~4.1.2"
44+
}
45+
}

‎src/app/app-routing.module.ts

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import { NgModule } from '@angular/core';
2+
import { RouterModule, Routes } from '@angular/router';
3+
4+
const routes: Routes = [];
5+
6+
@NgModule({
7+
imports: [RouterModule.forRoot(routes)],
8+
exports: [RouterModule]
9+
})
10+
export class AppRoutingModule { }

‎src/app/app.component.html

+534
Large diffs are not rendered by default.

‎src/app/app.component.scss

Whitespace-only changes.

‎src/app/app.component.spec.ts

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
import { TestBed } from '@angular/core/testing';
2+
import { RouterTestingModule } from '@angular/router/testing';
3+
import { AppComponent } from './app.component';
4+
5+
describe('AppComponent', () => {
6+
beforeEach(async () => {
7+
await TestBed.configureTestingModule({
8+
imports: [
9+
RouterTestingModule
10+
],
11+
declarations: [
12+
AppComponent
13+
],
14+
}).compileComponents();
15+
});
16+
17+
it('should create the app', () => {
18+
const fixture = TestBed.createComponent(AppComponent);
19+
const app = fixture.componentInstance;
20+
expect(app).toBeTruthy();
21+
});
22+
23+
it(`should have as title 'angular-responsive-sidebar'`, () => {
24+
const fixture = TestBed.createComponent(AppComponent);
25+
const app = fixture.componentInstance;
26+
expect(app.title).toEqual('angular-responsive-sidebar');
27+
});
28+
29+
it('should render title', () => {
30+
const fixture = TestBed.createComponent(AppComponent);
31+
fixture.detectChanges();
32+
const compiled = fixture.nativeElement;
33+
expect(compiled.querySelector('.content span').textContent).toContain('angular-responsive-sidebar app is running!');
34+
});
35+
});

‎src/app/app.component.ts

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import { Component } from '@angular/core';
2+
3+
@Component({
4+
selector: 'app-root',
5+
templateUrl: './app.component.html',
6+
styleUrls: ['./app.component.scss']
7+
})
8+
export class AppComponent {
9+
title = 'angular-responsive-sidebar';
10+
}

‎src/app/app.module.ts

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
import { NgModule } from '@angular/core';
2+
import { BrowserModule } from '@angular/platform-browser';
3+
4+
import { AppRoutingModule } from './app-routing.module';
5+
import { AppComponent } from './app.component';
6+
7+
@NgModule({
8+
declarations: [
9+
AppComponent
10+
],
11+
imports: [
12+
BrowserModule,
13+
AppRoutingModule
14+
],
15+
providers: [],
16+
bootstrap: [AppComponent]
17+
})
18+
export class AppModule { }

‎src/assets/.gitkeep

Whitespace-only changes.

‎src/environments/environment.prod.ts

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
export const environment = {
2+
production: true
3+
};

‎src/environments/environment.ts

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
// This file can be replaced during build by using the `fileReplacements` array.
2+
// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.
3+
// The list of file replacements can be found in `angular.json`.
4+
5+
export const environment = {
6+
production: false
7+
};
8+
9+
/*
10+
* For easier debugging in development mode, you can import the following file
11+
* to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.
12+
*
13+
* This import should be commented out in production mode because it will have a negative impact
14+
* on performance if an error is thrown.
15+
*/
16+
// import 'zone.js/dist/zone-error'; // Included with Angular CLI.

‎src/favicon.ico

948 Bytes
Binary file not shown.

‎src/index.html

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<!doctype html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="utf-8">
5+
<title>AngularResponsiveSidebar</title>
6+
<base href="/">
7+
<meta name="viewport" content="width=device-width, initial-scale=1">
8+
<link rel="icon" type="image/x-icon" href="favicon.ico">
9+
</head>
10+
<body>
11+
<app-root></app-root>
12+
</body>
13+
</html>

‎src/main.ts

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import { enableProdMode } from '@angular/core';
2+
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
3+
4+
import { AppModule } from './app/app.module';
5+
import { environment } from './environments/environment';
6+
7+
if (environment.production) {
8+
enableProdMode();
9+
}
10+
11+
platformBrowserDynamic().bootstrapModule(AppModule)
12+
.catch(err => console.error(err));

‎src/polyfills.ts

+65
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
/**
2+
* This file includes polyfills needed by Angular and is loaded before the app.
3+
* You can add your own extra polyfills to this file.
4+
*
5+
* This file is divided into 2 sections:
6+
* 1. Browser polyfills. These are applied before loading ZoneJS and are sorted by browsers.
7+
* 2. Application imports. Files imported after ZoneJS that should be loaded before your main
8+
* file.
9+
*
10+
* The current setup is for so-called "evergreen" browsers; the last versions of browsers that
11+
* automatically update themselves. This includes Safari >= 10, Chrome >= 55 (including Opera),
12+
* Edge >= 13 on the desktop, and iOS 10 and Chrome on mobile.
13+
*
14+
* Learn more in https://angular.io/guide/browser-support
15+
*/
16+
17+
/***************************************************************************************************
18+
* BROWSER POLYFILLS
19+
*/
20+
21+
/**
22+
* IE11 requires the following for NgClass support on SVG elements
23+
*/
24+
// import 'classlist.js'; // Run `npm install --save classlist.js`.
25+
26+
/**
27+
* Web Animations `@angular/platform-browser/animations`
28+
* Only required if AnimationBuilder is used within the application and using IE/Edge or Safari.
29+
* Standard animation support in Angular DOES NOT require any polyfills (as of Angular 6.0).
30+
*/
31+
// import 'web-animations-js'; // Run `npm install --save web-animations-js`.
32+
33+
/**
34+
* By default, zone.js will patch all possible macroTask and DomEvents
35+
* user can disable parts of macroTask/DomEvents patch by setting following flags
36+
* because those flags need to be set before `zone.js` being loaded, and webpack
37+
* will put import in the top of bundle, so user need to create a separate file
38+
* in this directory (for example: zone-flags.ts), and put the following flags
39+
* into that file, and then add the following code before importing zone.js.
40+
* import './zone-flags';
41+
*
42+
* The flags allowed in zone-flags.ts are listed here.
43+
*
44+
* The following flags will work for all browsers.
45+
*
46+
* (window as any).__Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame
47+
* (window as any).__Zone_disable_on_property = true; // disable patch onProperty such as onclick
48+
* (window as any).__zone_symbol__UNPATCHED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames
49+
*
50+
* in IE/Edge developer tools, the addEventListener will also be wrapped by zone.js
51+
* with the following flag, it will bypass `zone.js` patch for IE/Edge
52+
*
53+
* (window as any).__Zone_enable_cross_context_check = true;
54+
*
55+
*/
56+
57+
/***************************************************************************************************
58+
* Zone JS is required by default for Angular itself.
59+
*/
60+
import 'zone.js/dist/zone'; // Included with Angular CLI.
61+
62+
63+
/***************************************************************************************************
64+
* APPLICATION IMPORTS
65+
*/

‎src/styles.scss

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/* You can add global styles to this file, and also import other style files */

‎src/test.ts

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
2+
3+
import 'zone.js/dist/zone-testing';
4+
import { getTestBed } from '@angular/core/testing';
5+
import {
6+
BrowserDynamicTestingModule,
7+
platformBrowserDynamicTesting
8+
} from '@angular/platform-browser-dynamic/testing';
9+
10+
declare const require: {
11+
context(path: string, deep?: boolean, filter?: RegExp): {
12+
keys(): string[];
13+
<T>(id: string): T;
14+
};
15+
};
16+
17+
// First, initialize the Angular testing environment.
18+
getTestBed().initTestEnvironment(
19+
BrowserDynamicTestingModule,
20+
platformBrowserDynamicTesting()
21+
);
22+
// Then we find all the tests.
23+
const context = require.context('./', true, /\.spec\.ts$/);
24+
// And load the modules.
25+
context.keys().map(context);

‎tsconfig.app.json

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
/* To learn more about this file see: https://angular.io/config/tsconfig. */
2+
{
3+
"extends": "./tsconfig.json",
4+
"compilerOptions": {
5+
"outDir": "./out-tsc/app",
6+
"types": []
7+
},
8+
"files": [
9+
"src/main.ts",
10+
"src/polyfills.ts"
11+
],
12+
"include": [
13+
"src/**/*.d.ts"
14+
]
15+
}

‎tsconfig.json

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
/* To learn more about this file see: https://angular.io/config/tsconfig. */
2+
{
3+
"compileOnSave": false,
4+
"compilerOptions": {
5+
"baseUrl": "./",
6+
"outDir": "./dist/out-tsc",
7+
"forceConsistentCasingInFileNames": true,
8+
"strict": true,
9+
"noImplicitReturns": true,
10+
"noFallthroughCasesInSwitch": true,
11+
"sourceMap": true,
12+
"declaration": false,
13+
"downlevelIteration": true,
14+
"experimentalDecorators": true,
15+
"moduleResolution": "node",
16+
"importHelpers": true,
17+
"target": "es2015",
18+
"module": "es2020",
19+
"lib": [
20+
"es2018",
21+
"dom"
22+
]
23+
},
24+
"angularCompilerOptions": {
25+
"enableI18nLegacyMessageIdFormat": false,
26+
"strictInjectionParameters": true,
27+
"strictInputAccessModifiers": true,
28+
"strictTemplates": true
29+
}
30+
}

‎tsconfig.spec.json

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/* To learn more about this file see: https://angular.io/config/tsconfig. */
2+
{
3+
"extends": "./tsconfig.json",
4+
"compilerOptions": {
5+
"outDir": "./out-tsc/spec",
6+
"types": [
7+
"jasmine"
8+
]
9+
},
10+
"files": [
11+
"src/test.ts",
12+
"src/polyfills.ts"
13+
],
14+
"include": [
15+
"src/**/*.spec.ts",
16+
"src/**/*.d.ts"
17+
]
18+
}

‎tslint.json

+152
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,152 @@
1+
{
2+
"extends": "tslint:recommended",
3+
"rulesDirectory": [
4+
"codelyzer"
5+
],
6+
"rules": {
7+
"align": {
8+
"options": [
9+
"parameters",
10+
"statements"
11+
]
12+
},
13+
"array-type": false,
14+
"arrow-return-shorthand": true,
15+
"curly": true,
16+
"deprecation": {
17+
"severity": "warning"
18+
},
19+
"eofline": true,
20+
"import-blacklist": [
21+
true,
22+
"rxjs/Rx"
23+
],
24+
"import-spacing": true,
25+
"indent": {
26+
"options": [
27+
"spaces"
28+
]
29+
},
30+
"max-classes-per-file": false,
31+
"max-line-length": [
32+
true,
33+
140
34+
],
35+
"member-ordering": [
36+
true,
37+
{
38+
"order": [
39+
"static-field",
40+
"instance-field",
41+
"static-method",
42+
"instance-method"
43+
]
44+
}
45+
],
46+
"no-console": [
47+
true,
48+
"debug",
49+
"info",
50+
"time",
51+
"timeEnd",
52+
"trace"
53+
],
54+
"no-empty": false,
55+
"no-inferrable-types": [
56+
true,
57+
"ignore-params"
58+
],
59+
"no-non-null-assertion": true,
60+
"no-redundant-jsdoc": true,
61+
"no-switch-case-fall-through": true,
62+
"no-var-requires": false,
63+
"object-literal-key-quotes": [
64+
true,
65+
"as-needed"
66+
],
67+
"quotemark": [
68+
true,
69+
"single"
70+
],
71+
"semicolon": {
72+
"options": [
73+
"always"
74+
]
75+
},
76+
"space-before-function-paren": {
77+
"options": {
78+
"anonymous": "never",
79+
"asyncArrow": "always",
80+
"constructor": "never",
81+
"method": "never",
82+
"named": "never"
83+
}
84+
},
85+
"typedef": [
86+
true,
87+
"call-signature"
88+
],
89+
"typedef-whitespace": {
90+
"options": [
91+
{
92+
"call-signature": "nospace",
93+
"index-signature": "nospace",
94+
"parameter": "nospace",
95+
"property-declaration": "nospace",
96+
"variable-declaration": "nospace"
97+
},
98+
{
99+
"call-signature": "onespace",
100+
"index-signature": "onespace",
101+
"parameter": "onespace",
102+
"property-declaration": "onespace",
103+
"variable-declaration": "onespace"
104+
}
105+
]
106+
},
107+
"variable-name": {
108+
"options": [
109+
"ban-keywords",
110+
"check-format",
111+
"allow-pascal-case"
112+
]
113+
},
114+
"whitespace": {
115+
"options": [
116+
"check-branch",
117+
"check-decl",
118+
"check-operator",
119+
"check-separator",
120+
"check-type",
121+
"check-typecast"
122+
]
123+
},
124+
"component-class-suffix": true,
125+
"contextual-lifecycle": true,
126+
"directive-class-suffix": true,
127+
"no-conflicting-lifecycle": true,
128+
"no-host-metadata-property": true,
129+
"no-input-rename": true,
130+
"no-inputs-metadata-property": true,
131+
"no-output-native": true,
132+
"no-output-on-prefix": true,
133+
"no-output-rename": true,
134+
"no-outputs-metadata-property": true,
135+
"template-banana-in-box": true,
136+
"template-no-negated-async": true,
137+
"use-lifecycle-interface": true,
138+
"use-pipe-transform-interface": true,
139+
"directive-selector": [
140+
true,
141+
"attribute",
142+
"app",
143+
"camelCase"
144+
],
145+
"component-selector": [
146+
true,
147+
"element",
148+
"app",
149+
"kebab-case"
150+
]
151+
}
152+
}

0 commit comments

Comments
 (0)
Please sign in to comment.