refactor(core): remove deprecated OpaqueToken (#18971)

BREAKING CHANGE: `OpaqueToken` has been removed as it was deprecated since v4. Use `InjectionToken` instead.
PR Close #18971
This commit is contained in:
Olivier Combe
2017-08-31 10:56:26 +02:00
committed by Miško Hevery
parent 36d37cc6ae
commit 3c4eef8a86
10 changed files with 19 additions and 65 deletions

View File

@ -117,7 +117,7 @@ describe('Dependency Injection Tests', function () {
expect(element(by.css('#p8')).getText()).toEqual(expectedMsg);
});
it('P9 (OpaqueToken) displays as expected', function () {
it('P9 (InjectionToken) displays as expected', function () {
expectedMsg = 'APP_CONFIG Application title is Dependency Injection';
expect(element(by.css('#p9')).getText()).toEqual(expectedMsg);
});

View File

@ -280,13 +280,7 @@ Most importantly, the compiler only generates code to create instances of certai
### New instances
The compiler only allows metadata that create instances of these Angular classes.
Class | Module
-----------------|--------------
`OpaqueToken` | `@angular/core`
`InjectionToken` | `@angular/core`
The compiler only allows metadata that create instances of the class `InjectionToken` from `@angular/core`.
### Annotations/Decorators