Commit Graph

72 Commits

Author SHA1 Message Date
Paul Gschwendtner 29513296fb test: disable failing ivy example e2e tests (#28402)
PR Close #28402
2019-01-28 19:21:09 -08:00
Paul Gschwendtner 98e5af1480 build: switch example e2e tests to bazel (#28402)
* No longer builds the example e2e tests using "tsc". The examples are now built with Bazel and can therefore be built with Ivy by using the `--define=compile=aot` switch.
* No longer runs the example e2e tests using the protractor CLI. example e2e tests are executed with the Bazel protractor rule and can therefore run incrementally.

NOTE: Unit tests found within the examples are still running within the legacy jobs.

PR Close #28402
2019-01-28 19:21:09 -08:00
kwiateusz 657cf733a2 docs: ngComponentOutlet doc updated with new Injector creation (#27291)
PR Close #27291
2019-01-14 10:36:02 -08:00
George Kalpakas 50a91ba28c docs(upgrade): add gotchas/tips/example for multiple downgraded modules (#27217)
PR Close #27217
2018-12-20 16:20:41 -05:00
Igor Minar dacf58eb99 docs: remove obsolete packages/examples/web_workers/ts/.gitkeep (#27386)
PR Close #27386
2018-12-05 20:55:32 -08:00
Deltatiger 83c9bff242 docs(core): cleanup todo notes in ContentChild documentation examples (#26543)
PR Close #26543
2018-11-09 09:47:26 -08:00
George Kalpakas 7dbc103cbe fix(upgrade): improve downgrading-related error messages (#26217)
Make the error messages thrown when instantiating downgraded components,
injectables and modules more descriptive and actionable, also taking
into account incorrect use of the `downgradedModule` field.

PR Close #26217
2018-11-05 16:33:55 -08:00
George Kalpakas 93837e9545 feat(upgrade): support downgrading multiple modules (#26217)
Currently, calling `downgradeModule()` more than once is not supported.
If one wants to downgrade multiple Angular modules, they can create a
"super-module" that imports all the rest and downgrade that.

This commit adds support for downgrading multiple Angular modules. If
multiple modules are downgraded, then one must explicitly specify the
downgraded module that each downgraded component or injectable belongs
to, when calling `downgradeComponent()` and `downgradeInjectable()`
respectively.

No modification is needed (i.e. there is no need to specify a module for
downgraded components and injectables), if an app is not using
`downgradeModule()` or if there is only one downgraded Angular module.

Fixes #26062

PR Close #26217
2018-11-05 16:33:55 -08:00
Lars Gyrup Brink Nielsen e9e804fb02 feat(forms): add updateOn option to FormBuilder (#24599)
PR Close #24599
2018-11-01 15:31:11 -07:00
George Kalpakas 9e32dc7c95 build: upgrade `@types/jasminewd2` to 2.0.4 (#26139)
This commit also removes the extra jasminewd2 typings, since the changes
have been merged in the official typings with
DefinitelyTyped/DefinitelyTyped#28957.

PR Close #26139
2018-10-12 14:11:11 -07:00
Michael Giambalvo 16c03c0f38 fix(core): In Testability.whenStable update callback, pass more complete (#25010)
data about tasks.

When building a list of pending tasks for callers of whenStable(),
Testability will copy data about the task into a new object, in order to
avoid leaking references to tasks.

This change copies more properties from Tasks into the list of pending
tasks, as well as a reference to Task.data to give callers more
information about the tasks that are pending.

Specifically, this also copies runCount and task ID, which are needed in
order for callers to know when a given task is repeating.

PR Close #25010
2018-08-06 13:49:19 -07:00
Vani 7d006c5005 docs(core): fix tree-shakable spelling (#24057)
PR Close #24057
2018-08-06 13:40:15 -07:00
Brandon Roberts 1e5327872d docs(core): replace ReflectiveInjector example with Static Injector example (#25162)
PR Close #25162
2018-08-01 10:52:32 -07:00
cexbrayat be3cca4fd5
docs: tests for number/percent/currency pipe (#25028)
Will avoid errors in examples like the one fixed in #24661

Closes #25028
2018-07-23 13:18:23 -07:00
Judy Bogart f1ab394218
docs: add api doc to commonly queried elements 2018-07-20 12:39:10 -07:00
cexbrayat 270176bbe4 docs: more info on currency digits (#24661)
Adds an example of using the `currency` pipe with a currency that has no cents like CLP,
which will format the amount with no digits if `digitsInfo` is not provided:

    <!-- outputs CA$14.00 -->
    {{ 14 | currency:'CAD' }}
    <!-- outputs CLP14 -->
    {{ 14 | currency:'CLP' }}

Amends the docs, adds an example and fix an error with a current example.

PR Close #24661
2018-07-20 10:33:06 -07:00
Brandon Roberts 80a74b450a docs(forms): update form builder API reference (#24693)
PR Close #24693
2018-07-12 16:38:26 -04:00
George Kalpakas e01b539ee5 refactor: infer type for `it()` assertion functions (#19904)
PR Close #19904
2018-07-06 13:48:02 -07:00
George Kalpakas 00c110b055 build: upgrade jasmine (and related typings) to latest version (#19904)
With these changes, the types are a little stricter now and also not
compatible with Protractor's jasmine-like syntax. So, we have to also
use `@types/jasminewd2` for e2e tests (but not for non-e2e tests).

I also had to "augment" `@types/jasminewd2`, because the latest
typings from [DefinitelyTyped][1] do not reflect the fact that the
`jasminewd2` version (v2.1.0) currently used by Protractor supports
passing a `done` callback to a spec.

[1]: 566e039485/types/jasminewd2/index.d.ts (L9-L15)

Fixes #23952
Closes #24733

PR Close #19904
2018-07-06 13:48:02 -07:00
Sergej f974c48885 docs: describe rounding behaviour of 'DecimalPipe' (#24303)
PR Close #24303
2018-07-06 10:13:00 -07:00
Rob Wormald 3553977bd7 feat(core): add support for ShadowDOM v1 (#24718)
add a new ViewEncapsulation.ShadowDom option that uses the v1 Shadow DOM API to provide style encapsulation.

PR Close #24718
2018-07-02 14:37:41 -07:00
George Kalpakas abed2cd52c refactor(upgrade): fix examples for `strictPropertyInitialization` and remove internal comments (#18487) (#18487)
PR Close #18487

PR Close #18487
2018-06-27 15:01:47 -07:00
Peter Bacon Darwin bb6b59128f docs(upgrade): use a class for upgraded service (#18487) (#18487)
This makes the resulting use in Angular more ideomatic, since we can just
use the class type as the injection indicator.

PR Close #18487

PR Close #18487
2018-06-27 15:01:47 -07:00
Georgios Kalpakas 2ac2ab7ff6 docs(upgrade): add API docs for `downgradeModule()` (#18487) (#18487)
PR Close #18487

PR Close #18487
2018-06-27 15:01:47 -07:00
Georgios Kalpakas 0b3d25d67e docs(upgrade): update API docs for upgrade/static (#18487) (#18487)
PR Close #18487

PR Close #18487
2018-06-27 15:01:47 -07:00
Georgios Kalpakas 922908818f test: minor improvements in examples e2e tests script (#18487) (#18487)
PR Close #18487

PR Close #18487
2018-06-27 15:01:47 -07:00
Miško Hevery 166d90d2a9 ci: fix broken build 2018-06-25 11:36:35 -07:00
Judy Bogart 7d318743c1 docs: test doc for decorator templates (#23902) (#23902)
PR Close #23902

PR Close #23902
2018-06-25 10:49:31 -07:00
George Kalpakas 7d1f9c8a7c build: upgrade AngularJS typings (#24583)
Previously, we were using [@types/angularjs][1], which is deprecated and
outdated (hasn't been updated for over two years). This PR switches to
[@types/angular][2], which is regularly updated (based on the
definitions on [DefinitelyTyped][3]).

[1]: https://www.npmjs.com/package/@types/angularjs
[2]: https://www.npmjs.com/package/@types/angular
[3]: https://github.com/DefinitelyTyped/DefinitelyTyped

PR Close #24583
2018-06-25 09:30:46 -07:00
Rado Kirov c95437f15d build(bazel): Turning on strictPropertyInitialization for Angular. (#24572)
All errors for existing fields have been detected and suppressed with a
`!` assertion.

Issue/24571 is tracking proper clean up of those instances.

One-line change required in ivy/compilation.ts, because it appears that
the new syntax causes tsickle emitted node to no longer track their
original sourceFiles.

PR Close #24572
2018-06-25 07:57:13 -07:00
cexbrayat f3625e424b test(common): rename keyvalue e2e test (#24489)
PR Close #24489
2018-06-14 16:55:17 -07:00
Fabian Wiles 2b49bf77af feat(common): introduce KeyValuePipe (#24319)
PR Close #24319
2018-06-13 13:30:49 -07:00
sergeome 7966744a44 fix(common): titlecase pipe (#22600)
PR Close #22600
2018-03-23 13:42:51 -04:00
Igor Minar b43f8bc7d3 feat(core): upgrade rxjs to 6.0.0-alpha.4 (#22573)
PR Close #22573
2018-03-19 21:51:51 -07:00
Alex Eagle f9247e4b2e build: enable importHelpers in tsconfig (#22812)
This is the primary tsconfig file used for Bazel builds.
Previously, we enabled this option only for releases.

PR Close #22812
2018-03-15 21:16:03 -07:00
Michael Giambalvo 37fedd001c feat(core): add task tracking to Testability (#16863)
Allow passing an optional timeout to Testability's whenStable(). If
specified, if Angular is not stable before the timeout is hit, the
done callback will be invoked with a list of pending macrotasks.

Also, allows an optional update callback, which will be invoked whenever
the set of pending macrotasks changes. If this callback returns true,
the timeout will be cancelled and the done callback will not be invoked.

If the optional parameters are not passed, whenStable() will work
as it did before, whether or not the task tracking zone spec is
available.

This change also migrates the Testability unit tests off the deprecated
AsyncTestCompleter.

PR Close #16863
2018-03-14 08:48:48 -07:00
Alex Rickabaugh db56836425 feat: tree-shakeable providers API updates (#22655)
Rename @Injectable({scope -> providedIn}).

Instead of {providedIn: APP_ROOT_SCOPE}, accept {providedIn: 'root'}.
Also, {providedIn: null} implies the injectable should not be added
to any scope.

PR Close #22655
2018-03-13 09:28:05 -07:00
Alex Rickabaugh f8749bfb70 fix(core): export inject() from @angular/core (#22389)
inject() supports the ngInjectableDef-based configuration of the injector
(otherwise known as tree-shakeable services). It was missing from the
exported API of @angular/core, this PR adds it.

The test added here is correct in theory, but may pass accidentally due
to the decorator side-effect replacing the inject() call at runtime. An
upcoming compiler PR will strip reified decorators from the output
entirely.

Fixes #22388

PR Close #22389
2018-02-28 10:44:37 -08:00
Oussama Ben Brahim f1a063298e feat(core): set preserveWhitespaces to false by default (#22046)
Fixes #22027

PR Close #22046
2018-02-16 09:06:14 -08:00
Adrien Boullé 020338230f style: fix typos boostrap to bootstrap (#21917)
PR Close #21917
2018-02-15 09:54:00 -08:00
Matias Niemelä 831592c381 Revert "style: fix typos boostrap to bootstrap (#21917)"
This reverts commit 363498b6b4.
2018-02-14 22:56:44 -05:00
Adrien Boullé 363498b6b4 style: fix typos boostrap to bootstrap (#21917)
PR Close #21917
2018-02-14 18:21:52 -05:00
Misko Hevery 3d50fd7cac build: add bazel test rules for remainder of packages (#21053)
PR Close #21053
2017-12-22 13:10:51 -08:00
Misko Hevery 47e251a80a build: remove `main()` from specs (#21053)
PR Close #21053
2017-12-22 13:10:51 -08:00
George Kalpakas 3846f19f22 docs(core): move core examples into `examples/core/` directory
This allows examples to be found during aio's `yarn serve-and-sync`, which only
looks for examples in `packages/examples/<packageName>/**/*`, where
`packageName` is the name of the package that the modified file belonged to;
e.g. `core`, `common`, etc.).
2017-12-18 12:10:29 -08:00
Olivier Combe b7738e1fe5 feat(core): add source to `StaticInjectorError` message (#20817)
Closes #19302
PR Close #20817
2017-12-12 11:56:06 -08:00
luffySAMA c9ad529afc docs(common): fix mistakes in number pipe example (#20788)
PR Close #20788
2017-12-08 10:24:10 -08:00
Alex Eagle 5ec1717c58 fix: Update test code to type-check under TS 2.5 (#20175)
PR Close #20175
2017-11-15 18:12:16 -06:00
Harry Pfleger b4a39f9c30 docs(aio): fix -mm- to -MM- for month in DatePipe (#20315)
PR Close #20315
2017-11-10 10:58:45 -08:00
Victor Berchet f0764016f9
revert: feat(core): add source to `StaticInjectorError` message (#19482) (#20171)
This reverts commit faa621218e.
2017-11-03 14:51:06 -07:00