Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[docs] Improvements to Racer model docs #641

Merged
merged 1 commit into from
Jun 19, 2024
Merged

Conversation

ericyhwang
Copy link
Contributor

  • Overall:
    • Document *Promised methods added in racer@1.1.0, with examples
    • Change the very outdated "store" term to use "backend" instead
  • Main Models page:
    • Add textual overview of important sub-pages
    • Rewrite docs on creating models for clarity
    • Add docs for model.close()
  • Contexts:
    • Small rewrites for clarity
  • Events:
    • Recommend that new code use {useEventObjects: true}
    • Mention that TS types only support that event-objects callback format
    • Hide full docs on legacy event callbacks by default
  • Getters:
    • Add docs for getOrThrow and getOrDefault added in racer@2.1.0
    • Make a louder warning about in-place modififications of values returned by non-copying get* methods
  • Mutators:
    • Add section about error handling
    • Rewrite info about confirming mutations, now in its own section with examples
    • Add docs about *Promised mutator methods in that section
    • Document whenNothingPending() with appropriate warnings
  • Paths:
    • Include full example of model data structure
    • Update docs on local vs remote collections for clarity
  • Queries:
    • Add explanations on how to subscribe/fetch a query, via both callback and promise APIs
    • Add examples
  • Reactive functions:
    • Move model.evaluate to its own paragraph, to make it more clear what options applies to it vs model.start
    • Minor wording updates and clarifications
  • References:
    • Mention similarity to filesystem symlinks

- Overall:
  - Document `*Promised` methods added in racer@1.1.0, with examples
  - Change the very outdated "store" term to use "backend" instead
- Main Models page:
  - Add textual overview of important sub-pages
  - Rewrite docs on creating models for clarity
  - Add docs for `model.close()`
- Contexts:
  - Small rewrites for clarity
- Events:
  - Recommend that new code use `{useEventObjects: true}`
  - Mention that TS types only support that event-objects callback format
  - Hide full docs on legacy event callbacks by default
- Getters:
  - Add docs for `getOrThrow` and `getOrDefault` added in racer@2.1.0
  - Make a louder warning about in-place modififications of values returned by non-copying `get*` methods
- Mutators:
  - Add section about error handling
  - Rewrite info about confirming mutations, now in its own section with examples
  - Add docs about `*Promised` mutator methods in that section
  - Document `whenNothingPending()` with appropriate warnings
- Paths:
  - Include full example of model data structure
  - Update docs on local vs remote collections for clarity
- Queries:
  - Add explanations on how to subscribe/fetch a query, via both callback and promise APIs
  - Add examples
- Reactive functions:
  - Move `model.evaluate` to its own paragraph, to make it more clear what options applies to it vs `model.start`
  - Minor wording updates and clarifications
- References:
  - Mention similarity to filesystem symlinks
@ericyhwang ericyhwang merged commit bdddccc into master Jun 19, 2024
5 checks passed
@ericyhwang ericyhwang deleted the racer-doc-improvements branch June 19, 2024 01:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants