Skip to content

Commit a871e23

Browse files
JeanMechealxhub
authored andcommitted
docs: remove duplicate words. (#51215)
Using the `\b(\w+)\s+\1\b` we can find duplicate word. Let's remove them. PR Close #51215
1 parent 2274d15 commit a871e23

File tree

11 files changed

+16
-16
lines changed

11 files changed

+16
-16
lines changed

aio/content/examples/structural-directives/src/app/unless.directive.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { Directive, Input, TemplateRef, ViewContainerRef } from '@angular/core';
99
// #enddocregion no-docs
1010
*
1111
* If the expression assigned to `appUnless` evaluates to a truthy value
12-
* then the templated elements are removed removed from the DOM,
12+
* then the templated elements are removed from the DOM,
1313
* the templated elements are (re)inserted into the DOM.
1414
*
1515
* <div *appUnless="errorCount" class="success">

aio/content/guide/lifecycle-hooks.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ The `ngOnDestroy()` method is also the time to notify another part of the applic
101101

102102
### DestroyRef
103103

104-
In addition to to `ngOnDestroy()`, you can inject Angular's `DestroyRef` and register callback functions to be called when the enclosing context is destroyed. This can be useful for building reusable utilities that require cleanup.
104+
In addition to `ngOnDestroy()`, you can inject Angular's `DestroyRef` and register callback functions to be called when the enclosing context is destroyed. This can be useful for building reusable utilities that require cleanup.
105105

106106
Register a callback with the `DestroyRef`:
107107

aio/src/app/shared/location.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ export class LocationService {
146146

147147
const { pathname, search, hash } = anchor;
148148
// Fix in-page anchors that are supposed to point to fragments inside the page, but are resolved
149-
// relative the the root path (`/`), due to the base URL being set to `/`.
149+
// relative the root path (`/`), due to the base URL being set to `/`.
150150
// (See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/base#in-page_anchors.)
151151
const isInPageAnchor = anchor.getAttribute('href')?.startsWith('#') ?? false;
152152
const correctPathname = isInPageAnchor ? this.location.path() : pathname;

packages/core/src/linker/view_container_ref.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,7 @@ const R3ViewContainerRef = class ViewContainerRef extends VE_ViewContainerRef {
349349

350350
// This function supports 2 signatures and we need to handle options correctly for both:
351351
// 1. When first argument is a Component type. This signature also requires extra
352-
// options to be provided as as object (more ergonomic option).
352+
// options to be provided as object (more ergonomic option).
353353
// 2. First argument is a Component factory. In this case extra options are represented as
354354
// positional arguments. This signature is less ergonomic and will be deprecated.
355355
if (isComponentFactory) {

packages/core/src/render3/hooks.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,14 +124,14 @@ export function registerPostOrderHooks(tView: TView, tNode: TNode): void {
124124
* This is done by storing and maintaining flags in the view: the {@link InitPhaseState},
125125
* and the index within that phase. They can be seen as a cursor in the following structure:
126126
* [[onInit1, onInit2], [afterContentInit1], [afterViewInit1, afterViewInit2, afterViewInit3]]
127-
* They are are stored as flags in LView[FLAGS].
127+
* They are stored as flags in LView[FLAGS].
128128
*
129129
* 2. Pre-order hooks can be executed in batches, because of the select instruction.
130130
* To be able to pause and resume their execution, we also need some state about the hook's array
131131
* that is being processed:
132132
* - the index of the next hook to be executed
133133
* - the number of init hooks already found in the processed part of the array
134-
* They are are stored as flags in LView[PREORDER_HOOK_FLAGS].
134+
* They are stored as flags in LView[PREORDER_HOOK_FLAGS].
135135
*/
136136

137137

packages/core/test/linker/ng_module_integration_spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -770,7 +770,7 @@ describe('NgModule', () => {
770770
class MyService1 {
771771
public innerService: MyService2;
772772
constructor(injector: Injector) {
773-
// Create MyService2 before it it's initialized by TestModule.
773+
// Create MyService2 before it's initialized by TestModule.
774774
this.innerService = injector.get(MyService2);
775775
}
776776
}

packages/core/test/render3/deps_tracker_spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -371,7 +371,7 @@ describe('runtime dependency tracker', () => {
371371
directives: new Set([Component1]),
372372
});
373373

374-
// Modify the the module
374+
// Modify the module
375375
(MainModule as NgModuleType).ɵmod.declarations = [];
376376

377377
ans = depsTracker.getNgModuleScope(MainModule as NgModuleType);
@@ -400,7 +400,7 @@ describe('runtime dependency tracker', () => {
400400
directives: new Set([Component1]),
401401
});
402402

403-
// Modify the the module
403+
// Modify the module
404404
(MainModule as NgModuleType).ɵmod.declarations = [];
405405
depsTracker.clearScopeCacheFor(MainModule as NgModuleType);
406406

packages/forms/src/directives/abstract_control_directive.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ export abstract class AbstractControlDirective {
6060

6161
/**
6262
* @description
63-
* Reports whether a control is pending, meaning that that async validation is occurring and
63+
* Reports whether a control is pending, meaning that async validation is occurring and
6464
* errors are not yet available for the input value. If the control is not present, null is
6565
* returned.
6666
*/

packages/forms/src/model/abstract_model.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export const VALID = 'VALID';
3131
export const INVALID = 'INVALID';
3232

3333
/**
34-
* Reports that a control is pending, meaning that that async validation is occurring and
34+
* Reports that a control is pending, meaning that async validation is occurring and
3535
* errors are not yet available for the input value.
3636
*
3737
* @see {@link markAsPending}
@@ -56,7 +56,7 @@ export const DISABLED = 'DISABLED';
5656
* value.
5757
* * **INVALID**: Reports that a control is invalid, meaning that an error exists in the input
5858
* value.
59-
* * **PENDING**: Reports that a control is pending, meaning that that async validation is
59+
* * **PENDING**: Reports that a control is pending, meaning that async validation is
6060
* occurring and errors are not yet available for the input value.
6161
* * **DISABLED**: Reports that a control is
6262
* disabled, meaning that the control is exempt from ancestor calculations of validity or value.
@@ -321,7 +321,7 @@ export type ɵWriteable<T> = {
321321
export type ɵGetProperty<T, K> =
322322
// K is a string
323323
K extends string ? ɵGetProperty<T, ɵCoerceStrArrToNumArr<ɵTokenize<K, '.'>>> :
324-
// Is is an array
324+
// Is it an array
325325
ɵWriteable<K> extends Array<string|number> ? ɵNavigate<T, ɵWriteable<K>> :
326326
// Fall through permissively if we can't calculate the type of K.
327327
any;

packages/forms/test/reactive_integration_spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4187,7 +4187,7 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
41874187
// - FormControlDirective was destroyed and connection to a value accessor and view
41884188
// validators should also be destroyed.
41894189
// - Since there is a second instance of the FormControlDirective directive present in the
4190-
// template, we expect to see see calls to value accessor B (since it's applied to
4190+
// template, we expect to see calls to value accessor B (since it's applied to
41914191
// that directive instance) and validators applied on a control instance itself (not a
41924192
// part of a view setup).
41934193
expect(valueAccessorBSpy).toHaveBeenCalledWith('Updated Value');
@@ -4262,7 +4262,7 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
42624262
// - `FormControlName` was destroyed and connection to the value accessor A and
42634263
// validators should also be destroyed.
42644264
// - Since there is a second instance of `FormControlName` directive present in the
4265-
// template, we expect to see see calls to the value accessor B (since it's applied to
4265+
// template, we expect to see calls to the value accessor B (since it's applied to
42664266
// that directive instance) and validators applied on a control instance itself (not a
42674267
// part of a view setup).
42684268
expect(valueAccessorBSpy).toHaveBeenCalledWith('Updated value');

0 commit comments

Comments
 (0)