Skip to content

Commit d3ec569

Browse files
rbalicki2facebook-github-bot
authored andcommitted
fix typos in Relay comments
Reviewed By: tyao1 Differential Revision: D23759901 fbshipit-source-id: 0cf3f057e34e29c799a04c7ce0d319985fd9bca2
1 parent 92c8d68 commit d3ec569

File tree

5 files changed

+12
-16
lines changed

5 files changed

+12
-16
lines changed

packages/relay-experimental/useLazyLoadQueryNode.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,8 +95,8 @@ function useLazyLoadQueryNode<TQuery: OperationType>(args: {|
9595
if (__DEV__) {
9696
if (_maybeFastRefresh && _maybeFastRefresh.current) {
9797
/**
98-
* This block only runs during fast refresh, the current resource and
99-
* it's cache is disposed in the previous cleanup. Stop retaining and
98+
* This block only runs during fast refresh, as the current resource and
99+
* its cache are disposed in the previous cleanup. Stop retaining and
100100
* force a re-render to restart fetchObservable and retain correctly.
101101
*/
102102
_maybeFastRefresh.current = false;

packages/relay-runtime/store/RelayModernFragmentSpecResolver.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ class SelectorResolver {
325325
// NOTE: We manually create the request descriptor here instead of
326326
// calling createOperationDescriptor() because we want to set a
327327
// descriptor with *unaltered* variables as the fragment owner.
328-
// This is a hack that allows us to preserve exisiting (broken)
328+
// This is a hack that allows us to preserve existing (broken)
329329
// behavior of RelayModern containers while using fragment ownership
330330
// to propagate variables instead of Context.
331331
// For more details, see the summary of D13999308

packages/relay-runtime/store/RelayModernQueryExecutor.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -436,16 +436,16 @@ class Executor {
436436

437437
// In theory this doesn't preserve the ordering of the batch.
438438
// The idea is that a batch is always:
439-
// * at-most one non-incremental payload
440-
// * followed zero or more incremental payloads
439+
// * at most one non-incremental payload
440+
// * followed by zero or more incremental payloads
441441
// The non-incremental payload can appear if the server sends a batch
442-
// w the initial payload followed by some early-to-resolve incremental
442+
// with the initial payload followed by some early-to-resolve incremental
443443
// payloads (although, can that even happen?)
444444
if (nonIncrementalResponses.length > 0) {
445445
const payloadFollowups = this._processResponses(nonIncrementalResponses);
446-
// Please note, that we're passing `this._operation` to the publish
446+
// Please note that we're passing `this._operation` to the publish
447447
// queue here, which will later passed to the store (via notify)
448-
// to indicate that this is an operation that cause the store to update
448+
// to indicate that this is an operation that caused the store to update
449449
const updatedOwners = this._publishQueue.run(this._operation);
450450
this._updateOperationTracker(updatedOwners);
451451
this._processPayloadFollowups(payloadFollowups);

packages/relay-runtime/store/RelayModernStore.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -703,7 +703,7 @@ function initializeRecordSource(target: MutableRecordSource) {
703703
/**
704704
* Updates the target with information from source, also updating a mapping of
705705
* which records in the target were changed as a result.
706-
* Additionally, will marc records as invalidated at the current write epoch
706+
* Additionally, will mark records as invalidated at the current write epoch
707707
* given the set of record ids marked as stale in this update.
708708
*/
709709
function updateTargetFromSource(

packages/relay-runtime/store/RelayStoreTypes.js

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -248,8 +248,6 @@ export interface Store {
248248

249249
/**
250250
* Read the results of a selector from in-memory records in the store.
251-
* Optionally takes an owner, corresponding to the operation that
252-
* owns this selector (fragment).
253251
*/
254252
lookup(selector: SingularReaderSelector): Snapshot;
255253

@@ -259,7 +257,7 @@ export interface Store {
259257
* Optionally provide an OperationDescriptor indicating the source operation
260258
* that was being processed to produce this run.
261259
*
262-
* This method should return an array of the affected fragment owners
260+
* This method should return an array of the affected fragment owners.
263261
*/
264262
notify(
265263
sourceOperation?: OperationDescriptor,
@@ -275,7 +273,7 @@ export interface Store {
275273

276274
/**
277275
* Ensure that all the records necessary to fulfill the given selector are
278-
* retained in-memory. The records will not be eligible for garbage collection
276+
* retained in memory. The records will not be eligible for garbage collection
279277
* until the returned reference is disposed.
280278
*/
281279
retain(operation: OperationDescriptor): Disposable;
@@ -586,14 +584,12 @@ export interface IEnvironment {
586584
/**
587585
* EXPERIMENTAL
588586
* Returns the default render policy to use when rendering a query
589-
* that uses Relay Hooks
587+
* that uses Relay Hooks.
590588
*/
591589
UNSTABLE_getDefaultRenderPolicy(): RenderPolicy;
592590

593591
/**
594592
* Read the results of a selector from in-memory records in the store.
595-
* Optionally takes an owner, corresponding to the operation that
596-
* owns this selector (fragment).
597593
*/
598594
lookup(selector: SingularReaderSelector): Snapshot;
599595

0 commit comments

Comments
 (0)