Skip to content

(DOCSP-39513): Consolidate Create page #3270

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

Merged
merged 38 commits into from
Jun 25, 2024

Conversation

dacharyc
Copy link
Collaborator

@dacharyc dacharyc commented May 22, 2024

Pull Request Info - SDK Docs Consolidation

Jira ticket: https://jira.mongodb.org/browse/DOCSP-39513

Staged Page

New consolidated pages:

Existing pages, ported over to the consolidated IA and updated for product naming/metadata:

Page Source

Add links to every SDK's pages where you got the SDK-specific information:

PR Author Checklist

Before requesting a review for your PR, please check these items:

  • Open the PR against the feature-consolidated-sdk-docs branch instead of master
  • Tag the consolidated page for:
    • genre
    • meta.keywords
    • meta.description

Naming

  • Update Realm naming and the language around persistence layer/local/device per this document
  • Include .rst files comply with the naming guidelines
    Note for Reviewer: The .rst files were named for a single create page. Having split the create page into 3, the names no longer comply with the guidelines. As this is around ~140 files, I didn't want to rename them all - but we may want to consider whether I should go through the effort, and/or what the naming guidelines look like as the IA evolves.

Links and Refs

  • Create new consolidated SDK ref targets starting with "_sdks-" for relevant sections
  • Remove or update any SDK-specific refs to use the new consolidated SDK ref targets
  • Update any Kotlin API links to use the new Kotlin SDK roles

Content

  • Shared code boxes have snippets or placeholders for all 9 languages
  • API description sections have API details or a generic placeholder for all 9 languages
  • Check related pages for relevant content to include
  • Create a ticket for missing examples in each relevant SDK: Consolidation Gaps epic

Reviewer Checklist

As a reviewer, please check these items:

  • Shared code example boxes contain language-specific snippets or placeholders for every language
  • API reference details contain working API reference links or generic content
  • Realm naming/language has been updated
  • All relevant content from individual SDK pages is present on the consolidated page

Copy link

github-actions bot commented May 22, 2024

Readability for Commit Hash: 19b0f29

You can see any previous Readability scores (if they exist) by looking
at the comment's history.

Readability scores for changed documents:

  • source/sdk/react-to-changes: Grade Level: 8.7, Reading Ease: 41.22
  • source/sdk/model-data/relationships: Grade Level: 19.0, Reading Ease: -12.45
  • source/sdk/model-data/supported-types: Grade Level: 9.4, Reading Ease: 39.4
  • source/sdk/model-data/object-models: Grade Level: 8.1, Reading Ease: 48.06
  • source/sdk/files/configure-and-open: Grade Level: 6.8, Reading Ease: 67.76
  • source/sdk/crud/threading: Grade Level: 9.2, Reading Ease: 40.01
  • source/sdk/crud/update: Grade Level: 11.9, Reading Ease: 22.07
  • source/sdk/crud/read: Grade Level: 8.1, Reading Ease: 58.89
  • source/sdk/crud/create: Grade Level: 8.8, Reading Ease: 57.06
  • source/sdk/crud/create/create-object-types: Grade Level: 9.4, Reading Ease: 50.23
  • source/sdk/crud/create/create-property-types: Grade Level: 8.8, Reading Ease: 51.65

For Grade Level, aim for 8 or below.

For Reading Ease scores, aim for 60 or above:

Score Difficulty
90-100 Very Easy
80-89 Easy
70-79 Fairly Easy
60-69 Medium
50-59 Fairly Hard
30-49 Hard
0-29 Very Hard

For help improving readability, try Hemingway App.

@dacharyc dacharyc marked this pull request as ready for review May 24, 2024 21:01
@dacharyc dacharyc added the merge to feature branch Unreleased feature - do not merge to Master label May 24, 2024
@cbullinger cbullinger self-requested a review June 20, 2024 15:24
Copy link
Collaborator

@cbullinger cbullinger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still need to review Create Property Types, but figured there's plenty of feedback for you to sift through so sorry

@@ -15,7 +15,7 @@ Read and Write Data
The following pages contain information about how to read and write data,
manage objects across threads, and use the Atlas Device SDK query engines:

- :ref:`sdks-crud-create`
- :ref:`sdks-create-object-methods`
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this be updated now that the consolidated page is split into 3 child pages under Create?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI I've changed this back to sdks-crud-create after moving this back to a container page with content - i.e. a landing page. So this can be the main destination for "create" content.

.. _sdks-create-object-methods:

=====================
Create Object Methods
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nit] This feels out of place with the two other child page titles. plus the "methods" renders the title a noun instead of an action, no?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Capturing this detail on the PR in case there are questions in the future. Cory and I discussed this offline and decided to try it with this page as a parent page called "Create Objects" and the other two pages as child pages, instead of the three being sibling pages. We can change this in the future if we decide this is a pattern we don't want to use (the create methods as the landing page) - we can revisit before we merge the feature branch and move the content if we need to.

Comment on lines 34 to 35
:ref:`sdks-configure-and-open-database` or
:ref:`sdks-configure-and-open-synced-database`.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[note] it's really hard to parse these two links in the rendered text since these page titles are very nearly identical

@@ -11,6 +11,7 @@ You can also return values from the write transaction callback function.

.. warning:: Write RealmObjects to One Realm File
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this unique to the Flutter SDK? if so, should we make that clear? it seems potentially confusing to see this big red warning that seems potentially applicable to other sdks

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The exception type is probably specific to Flutter. But the general info applies to more than one SDK - I know, for example, in Swift the DB throws an error if you try to write an object to a DB that is already managed by another DB.

We do explain that in the "Managed Objects" section, with a link to the section on copying a managed object to another DB. So maybe this warning isn't needed? I'll have a think about it.

For more information about modeling an object, refer to:
:ref:`sdks-object-models`.

.. include:: /includes/sdk-examples/crud/create-realm-object-model.rst
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fyi - we should models for all of the Kotlin examples, so these should be easy to pop in as part of the follow-up tickets

Copy link
Collaborator

@cbullinger cbullinger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Amazing job, @dacharyc. This was a tremendous amount of work. I'm sorry it took me so long to finish my review!

~~~~~~~~~~~~~~~~~~~~~

Like their native counterparts, the SDK's set data type stores unique values.
These values may be of any supported type except another collection.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in Kotlin, they can't contain an embedded object either

@@ -0,0 +1 @@
JavaScript does not currently have a dedicated counter property type.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it does now! 🥳 the new page should be available to merge to the feature branch this week

@dacharyc dacharyc merged commit ae0e146 into mongodb:feature-consolidated-sdk-docs Jun 25, 2024
6 checks passed
@dacharyc dacharyc deleted the DOCSP-39513 branch June 25, 2024 21:00
@docs-builder-bot
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merge to feature branch Unreleased feature - do not merge to Master
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants