99 Commits

Author SHA1 Message Date
Alan Agius
9ebca6b8d6 build: update karma-jasmine-html-reporter to 1.5.0 2020-06-01 15:02:15 -04:00
Alan Agius
617f46fb57 build: update to karma-jasmine to 3.3.0 2020-06-01 15:02:15 -04:00
Alan Agius
f9da2d8eb2 style: format tslint.json.template 2020-06-01 14:52:54 -04:00
Cyrille Tuzi
2039527201 feat(@schematics/angular): add tslint no-any and typedef rules when in strict mode 2020-06-01 14:52:54 -04:00
Alan Agius
bede23226a feat(@schematics/angular): add solutions style tsconfig structure
In version 3.9, TypeScript introduced the concept of "Solutions Style" tsconfig to improve developer experience.

More info: https://devblogs.microsoft.com/typescript/announcing-typescript-3-9-rc/#solution-style-tsconfig

Closes #17493 and closes #8138
2020-05-20 12:12:33 -07:00
Alan Agius
56bba34d75 fix(@schematics/angular): address vulnerability in protractor
potractor <7 contains a low severity vulnerability due to one of its dependencies (yargs-parser)

See: https://npmjs.com/advisories/1500

Fixes #17642
2020-05-15 14:44:45 +01:00
Alan Agius
112e11cc9b build: generate project using karma-coverage-istanbul-reporter using 3.0.2 2020-05-11 16:37:10 -04:00
Alan Agius
0fd3c550b5 feat(@schematics/angular): update compiler options target and module settings
With this change we update the target and module settings of various compilation units.

- We replace ES5 target in protractor. Protractor runs on Node.Js which support ES2018
- For applications we now use `ES2020` instead of `ESNext` as a module to avoid unexpected changes in behaviour

This changes also adds a migration to update existing projects and also removes `module` from the Universal tsconfig as per #17352 to enable lazy loading on the server.
2020-05-06 11:42:35 -07:00
Alan Agius
cbf0feb005 feat(@schematics/angular): enable stricter type checking and optimization effective coding rules
With this change we enable stricter type checking and optimization effective coding rules when using the `--strict` option.

Changes in schematics
- `ng-new`: A prompt for the `--strict` option was added. This option is a proxy and will be passed to the application and workspace schematics.
- `application`: A `package.json` was added in the `app` folder, to tell the bundlers whether the application is free from side-effect code. When `strict` is `true`. the `sideEffects` will be set `false`.
- `workspace` When `strict` is true, we add stricter TypeScript and Angular type-checking options.

Note: AIO is already using these strict TypeScript compiler settings. PR to enable `strictTemplates`  https://github.com/angular/angular/pull/36391

Reference: TOOL-1366
2020-05-05 11:44:19 -07:00
Alan Agius
371e44867c fix(@schematics/angular): don't add @angular/language-service in new Angular projects
This package is no longer required since the VS code extension is already shipped with it.
2020-05-05 10:50:27 -07:00
Alan Agius
e2eed2c8f8 build: update several packages 2020-05-04 10:51:49 -07:00
mgechev
460977d76e build: update to codelyzer@6.0.0-next.1 2020-04-24 09:50:14 -07:00
Alan Agius
f0e6a69250 feat(@schematics/angular): update karma to 5.0.0
Related to: https://github.com/angular/angular-cli/pull/17435
2020-04-13 11:32:38 -07:00
Wojciech Okoński
ed90080f85 style(@schematics/angular): prevent adding redundant whitespace in generated angular.json file
Previously "ng new" was generating angular.json file containing redundant whitespace after "version" property.
When file was edited some IDEs automatically removed this whitespace making additional change in diff.
If "packageManager" option is used, whitespace is still present.
2020-03-23 14:19:12 -07:00
Alan Agius
9b788b9125 build: update jasmine-spec-reporter to version 5 2020-03-23 14:17:54 -07:00
Alan Agius
df4382f082 feat(@schematics/angular): update default tslint.json rules
In tslint version 6, several recommanded rules have been removed in the following PRs:
https://github.com/palantir/tslint/pull/4871 https://github.com/palantir/tslint/pull/4312

With this change, we bring back these rules in the CLI.
2020-03-16 21:41:48 -07:00
Alan Agius
ab7cf8be8e feat(@schematics/angular): generate new projects with tslint 6.1.0
tslint 6.1 adds support for TypeScript 3.8 syntax

See: https://github.com/palantir/tslint/blob/master/CHANGELOG.md#v610
2020-03-16 21:41:48 -07:00
mgechev
032e2be28a refactor(@schematics/angular): remove redundant typeRoots
By default TypeScript will look up in this directory (see [docs](https://www.typescriptlang.org/docs/handbook/tsconfig-json.html#types-typeroots-and-types)).
2020-03-04 12:56:29 -08:00
Jonathan Chase
3e713a9075 feat(@schematics/angular): set quote_type = single in .editorconfig 2020-02-27 11:22:03 -08:00
Alan Agius
67fd5f52ef fix(@schematics/angular): update protractor version for new projects
New projects will now be created with `~5.4.3`
2020-01-29 10:21:17 -08:00
Alan Agius
9c9d2de6bc revert: "fix(@schematics/angular): add skipLibCheck to workspace tsconfig"
This reverts commit a8c60cb8b976d50c898607a5a5bf4fe84f0b2bfb.

Closes: #16696
2020-01-29 10:20:50 -08:00
Daniele Morosinotto
3aacf41057 fix(@schematics/angular): regression tsconfig.json #16708 (#16709)
* fix(@schematics/angular): regression tsconfig.json

fix(@schematics/angular): regression tsconfig.json  …
Unverified
0e318ae
Regression in tsconfig.json set `"outDir": "./dist/out-tsc"` for problems in VSCode TS(2307) when building library referred in tsconfig "paths" 
 
Closes: #16708

* fix(@schematics/angular): regression tsconfig.json

Improve paths in root tsconfig.json for better DX experience when using auto imports in IDE's.

Closes #16709

* fix(@schematics/angular): regression tsconfig.json

Improve paths in root tsconfig.json for better DX experience when using auto imports in IDE's.
Fix code lint.

Closes #16709

* fix(@schematics/angular): regression tsconfig.json

Improve paths in root tsconfig.json for better DX experience when using auto imports in IDE's.
Fix test code to conform new behaviour.

Closes #16709
2020-01-23 17:58:38 -08:00
Alan Agius
a8c60cb8b9 fix(@schematics/angular): add skipLibCheck to workspace tsconfig
Add skipLibCheck to speed up TypeScript analysis and prevent compilation errors caused by incompatible declaration files which were generated with older/new TS versions
2020-01-16 14:48:23 -08:00
Alan Agius
63957ae127 feat(@schematics/angular): update karma and karma-jasmine 2020-01-07 10:29:23 -08:00
Alan Agius
be1bcbaead fix(@schematics/angular): improve paths and exclude options
Currently the library schematic doesn't support adding a secondary entry-point and having deep imports is not recommanded.

It's best if paths are more stricter when having a secondary entry-point instead of a wildcard.

Instead of :
```
"lib/*": [
  "dist/lib/*"
]
```

Users should configure:
```
"lib/secondary": [
  "dist/lib/secondary"
]
```

This would allow a better DX experience when using auto imports in IDE's.

Closes: #15952
2019-12-03 12:37:07 -08:00
Alan Agius
b1fba1e0c1 fix(@schematics/angular): update @types/jasmine to 3.5 to match version of jasmine-core 2019-12-02 10:17:01 -08:00
Filipe Silva
5f8e8083b2 fix(@schematics/angular): remove ngcc postinstall hook
Partially addresses #16017
2019-11-11 09:14:24 -08:00
Amadou Sall
0e3d8e4a64 feat(@schematics/angular): add packageManager option
closes #15875
2019-10-25 09:53:12 -07:00
Alan Agius
0074abfbe8 feat(@schematics/angular): update to TypeScript 3.6 2019-10-21 09:37:29 -07:00
Filipe Silva
940276f554 fix(@schematics/angular): update ngcc postinstall command 2019-10-15 19:19:05 -07:00
Filipe Silva
318396345a feat(@schematics/angular): use ngcc on postinstall (#15801)
* build: use FW 9.0.0-next.10

* feat(@schematics/angular): use ngcc on postinstall

This should improve the time first builds take.

Part of https://github.com/angular/angular/pull/32999

Blocked on an Angular release that includes https://github.com/angular/angular/pull/33049
2019-10-10 12:39:10 -07:00
Alan Agius
35edccf4b4 Update several dependencies (#15797)
* feat(@schematics/schematics): update serveral dependencies of blank projects

* feat(@schematics/angular): update serveral dependencies of new workspaces
2019-10-09 11:04:25 -07:00
mgechev
5393041747 fix(@schematics/angular): drop deprecated tslint rule
>no-use-before-declare is deprecated. Since TypeScript 2.9. Please use the built-in compiler checks instead.
2019-09-27 14:40:05 -07:00
mgechev
e2e7dee752 feat(@schematics/angular): use codelyzer@5.1.2 2019-09-27 14:39:50 -07:00
Alan Agius
438e2eb4a7 feat(@schematics/angular): add strict compiler option to workspace tsconfig (#14905)
Closes #14694
2019-09-18 14:51:12 +01:00
Alan Agius
ad8acb0d23 build: bump angular dev packages to latest next versions 2019-08-22 09:41:28 -07:00
Alan Agius
c1523d220a build: update @types/jasmine to version ~3.4.0 2019-08-19 12:22:57 -07:00
Alan Agius
0d7dbc7f09 feat(@schematics/angular): update workspace dev dependencies 2019-08-16 09:31:30 -07:00
Alan Agius
96c457d6a5 refactor: add enableIvy: true until FW flips it on by default 2019-08-16 09:31:02 -07:00
Charles Lyding
5a7b823b28 test: remove use of deprecated synchronous test helper runSchematic 2019-08-08 08:27:31 -07:00
Alan Agius
8aa99bd288 refactor(@schematics/angular): remove unused schema properties from workspace schema
workspace schematic is internal and hence we can safely remove unused properties.
2019-08-05 17:58:21 -07:00
Alan
fc1fda2663 fix(@schematics/angular): add differential loading profiling file to gitignore
When differential loading enabled we will have different profiling files for every build target

Ex:
```
chrome-profiler-events-es2015.json
speed-measure-plugin-es2015.json
chrome-profiler-events-es5.json
speed-measure-plugin-es5.json
```
2019-07-24 19:05:23 -07:00
Minko Gechev
814b3c586c fix(@schematics/angular): set proper severity of the tslint deprecation rule 2019-06-27 09:25:08 -07:00
Alan
555668c987 feat(@schematics/angular): add fullTemplateTypeCheck and strictInjectionParameters to workspace tsconfig.json
Closes #14794
2019-06-17 11:00:09 -07:00
Alan Agius
c6fb34a092 fix(@schematics/angular): enable tsc downlevelIteration
We by default now use ES2015. Users can use ES2015 iterations however the ES5 build will fail.

Fixes #14697
2019-06-07 13:00:28 -07:00
Charles Lyding
6b28d3ac51 fix(@schematics/angular): remove emitDecoratorMetadata TS option for new applications 2019-05-23 19:12:40 +02:00
Alan Agius
0d235e1ef4 feat(@schematics/angular): update karma to 4.1.x 2019-04-16 09:41:11 -07:00
Alan Agius
58fb593787 feat(@schematics/angular): update several workspace dependencies
With this change we update ng-packagr, jasmine-core and tslint.
2019-04-15 11:09:13 -07:00
Alan Agius
718ed37684 feat(@schematics/angular): set workspace tsconfig target to es2015 2019-04-15 11:03:09 -07:00
Charles Lyding
a0a583adaa fix(@schematics/angular): remove unused core-js dependency from new projects
Required polyfills are now managed directly by the build system.  If additional polyfills are required, packages can be manually added as needed.
2019-04-04 09:28:02 -07:00