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: /docs/concepts/features-overview/ #725

Merged
merged 6 commits into from
May 22, 2024
Merged

Conversation

Yohe-Am
Copy link
Contributor

@Yohe-Am Yohe-Am commented May 16, 2024

  • Re-does the feature overview page of the documentation.

Summary by CodeRabbit

  • New Features

    • Added a "Features Roadmap" component to the website, displaying a list of features with details and links.
  • Documentation

    • Updated various guides and reference documents to improve clarity and presentation of code examples.
    • Added new sections for various features such as Typegate, Typegraph, Runtimes, Prisma, Auth, Tooling, and SDK.
  • Bug Fixes

    • Corrected a typo in the GraphQL runtimes reference documentation.
  • Refactor

    • Replaced SDKTabs and TabItem components with TGExample for better code example presentation.
    • Adjusted the MiniQL component to handle optional properties and default settings.

Copy link
Contributor

coderabbitai bot commented May 16, 2024

Walkthrough

The recent updates involve significant changes across various components and documentation files. Key modifications include updating platform specifications in the lock file, enhancing documentation with new import statements and example structures, and refining the MiniQL component properties. Additionally, a new FeaturesRoadmap component was introduced to display feature details on the website. These changes aim to improve functionality, clarity, and presentation across the project.

Changes

File(s) Change Summary
.ghjk/lock.json Updated platform from aarch64-darwin to x86_64-linux; added a new entry with version v2.4.0 and related details.
website/docs/concepts/features-overview/index.mdx Added import statements and new sections for various Features.
website/docs/guides/external-functions/index.mdx Restructured code snippets and removed SDKTabs and TabItem components.
website/docs/guides/rest/index.mdx Replaced SDKTabs and TabItem with TGExample, updated imports, and restructured code blocks.
website/docs/guides/securing-requests/index.mdx Reorganized authentication and policy code, adjusting components for better example presentation.
website/docs/reference/runtimes/graphql/index.mdx Corrected a typo in the description section.
website/shared/s3/index.mdx Removed SDKTabs and TabItem imports, restructured JSX layout, and adjusted TGExample components.
website/src/components/MiniQL/index.tsx Updated MiniQLProps interface to include optional properties and adjusted rendering logic.
website/src/pages/features/index.tsx Added new FeaturesRoadmap component to render feature details and links, along with Feature component for individual feature display.

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 25

Out of diff range and nitpick comments (7)
website/docs/reference/runtimes/graphql/index.mdx (1)

Line range hint 13-15: The addition of the TGExample component with Python and TypeScript examples is correctly implemented.

To address the static analysis hints, ensure that the require statements are correctly paired with double quotes:

- python={require("../../../../../examples/typegraphs/graphql.py")}
- typescript={require("!!code-loader!../../../../../examples/typegraphs/graphql.ts")}
- query={require("./graphql.graphql")}
+ python={require("../../../../../examples/typegraphs/graphql.py")}
+ typescript={require("!!code-loader!../../../../../examples/typegraphs/graphql.ts")}
+ query={require("./graphql.graphql")}
website/src/pages/features/index.tsx (2)

23-23: Use a more descriptive class name.

Consider using a more descriptive class name instead of "gap-2 flex max-w-full my-10" to improve readability and maintainability.


82-82: Use a more descriptive class name.

Consider using a more descriptive class name instead of "flex flex-col gap-1" to improve readability and maintainability.

website/docs/guides/external-functions/index.mdx (1)

Line range hint 69-69: Add missing article.

Consider adding "the" before "rest of functionality" for better readability.

- To do anything meaningful with custom functions, you'll want to access the rest of functionality implemented on your typegraph.
+ To do anything meaningful with custom functions, you'll want to access the rest of the functionality implemented on your typegraph.
website/docs/guides/securing-requests/index.mdx (1)

Line range hint 47-47: Add missing article.

Consider adding "a" before "guard" for better readability.

- `from_context` acts as guard preventing the materalizer from being accessed unless the named data is found in the context.
+ `from_context` acts as a guard preventing the materalizer from being accessed unless the named data is found in the context.
website/src/components/MiniQL/index.tsx (2)

86-89: Use a more descriptive class name.

Consider using a more descriptive class name instead of "md:grid @2XL:grid-cols-2" to improve readability and maintainability.


146-146: Use a more descriptive class name.

Consider using a more descriptive class name instead of "flex flex-col graphiql-container" to improve readability and maintainability.

website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/guides/external-functions/index.mdx Outdated Show resolved Hide resolved
website/docs/guides/securing-requests/index.mdx Outdated Show resolved Hide resolved
website/src/components/MiniQL/index.tsx Show resolved Hide resolved
@Yohe-Am Yohe-Am force-pushed the docs/features-overview branch from 71e4f27 to 59337ee Compare May 16, 2024 03:27
@Yohe-Am
Copy link
Contributor Author

Yohe-Am commented May 16, 2024

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 33

Out of diff range and nitpick comments (12)
website/docs/guides/rest/index.mdx (3)

Line range hint 23-23: Use a hyphen in "browser-based".

- A browser based explorer for the OpenAPI schema is served under `{typegate_url}/{typegraph}/rest` as well.
+ A browser-based explorer for the OpenAPI schema is served under `{typegate_url}/{typegraph}/rest` as well.

Line range hint 25-25: Consider changing "todo" to "to-do" or "to do".

- {/* todo: link to the expample's redoc*/}
+ {/* to-do: link to the example's redoc*/}

Line range hint 25-25: TODO: Add link to the example's redoc.

Do you want me to generate the link or open a GitHub issue to track this task?

website/shared/s3/index.mdx (1)

Line range hint 8-8: Use "set up" instead of "setup" as a verb.

- For the following example, you'll need to setup your S3 compatible store first.
+ For the following example, you'll need to set up your S3 compatible store first.
website/docs/reference/runtimes/graphql/index.mdx (2)

Line range hint 13-15: Fix the unpaired quotation marks in the require statements.

-  python={require("../../../../../examples/typegraphs/graphql.py")}
-  typescript={require("!!code-loader!../../../../../examples/typegraphs/graphql.ts")}
-  query={require("./graphql.graphql")}
+  python={require("!!code-loader!../../../../../examples/typegraphs/graphql.py")}
+  typescript={require("!!code-loader!../../../../../examples/typegraphs/graphql.ts")}
+  query={require("!!code-loader!./graphql.graphql")}

Line range hint 23-23: Correct the grammatical number of the noun.

- Other type enforcement rules also exists:
+ Other type enforcement rules also exist:
website/docs/guides/external-functions/index.mdx (1)

Line range hint 69-69: Add the missing article.

- you'll want to access the rest of functionality implemented on your typegraph.
+ you'll want to access the rest of the functionality implemented on your typegraph.
website/docs/guides/securing-requests/index.mdx (5)

Line range hint 25-25: Consider a shorter alternative to avoid wordiness.

- The following example uses basic authentication in order to only allow access for admin users.
+ The following example uses basic authentication to allow access only for admin users.

Line range hint 59-59: Use a hyphen for "policy-based".

- The primary authorization paradigm used in typegraphs is [policy based access control](/docs/reference/policies#policy-based-access-control-pbac).
+ The primary authorization paradigm used in typegraphs is [policy-based access control](/docs/reference/policies#policy-based-access-control-pbac).

Line range hint 65-65: Add a comma for clarity.

- the recommended way for writing policies today and the following example demonstrates how.
+ the recommended way for writing policies today, and the following example demonstrates how.

Line range hint 93-95: Avoid repetitive sentence beginnings.

Consider rewording the sentences to avoid starting three successive sentences with "If".

- If any one of attached policy returns `true`, the request immediately gains access.
- If a policy returns `false`, the request is immediately denied access.
- If the policy means to defer decision to other attached policies, it can return null instead.
+ If any one of the attached policies returns `true`, the request immediately gains access. A policy returning `false` will immediately deny access. To defer the decision to other attached policies, a policy can return `null` instead.

Line range hint 99-102: Fix loose punctuation marks.

Ensure consistent punctuation for list items.

- `Policy.public`: allow any request.
- `Policy.internal`: allow requests originating from within typegraph like custom functions.
- `Policy.on`: use different policies depending on request effect. Useful for policy shared across many materalizers.
- `Policy.context`: generate a policy using a simple pattern matching on context object fields.
+ `Policy.public`: allow any request.
+ `Policy.internal`: allow requests originating from within typegraph, like custom functions.
+ `Policy.on`: use different policies depending on request effect. Useful for policies shared across many materalizers.
+ `Policy.context`: generate a policy using a simple pattern matching on context object fields.

website/docs/guides/securing-requests/index.mdx Outdated Show resolved Hide resolved
website/docs/guides/securing-requests/index.mdx Outdated Show resolved Hide resolved
website/docs/guides/rest/index.mdx Outdated Show resolved Hide resolved
website/shared/s3/index.mdx Show resolved Hide resolved
website/docs/reference/runtimes/graphql/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
Copy link

codecov bot commented May 16, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 74.05%. Comparing base (24963ce) to head (9be1c56).

Current head 9be1c56 differs from pull request most recent head 03e860e

Please upload reports for the commit 03e860e to get more accurate results.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #725      +/-   ##
==========================================
+ Coverage   73.52%   74.05%   +0.52%     
==========================================
  Files         120      120              
  Lines       14142    13777     -365     
  Branches     1416     1407       -9     
==========================================
- Hits        10398    10202     -196     
+ Misses       3717     3549     -168     
+ Partials       27       26       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 18

Out of diff range and nitpick comments (2)
website/docs/guides/rest/index.mdx (1)

Line range hint 25-25: Add a hyphen in "todo".

- {/* todo: link to the expample's redoc*/}
+ {/* to-do: link to the example's redoc*/}
website/docs/reference/runtimes/graphql/index.mdx (1)

Line range hint 13-15: Fix the unpaired quotation marks in the require statements.

-  python={require("../../../../../examples/typegraphs/graphql.py")}
-  typescript={require("!!code-loader!../../../../../examples/typegraphs/graphql.ts")}
-  query={require("./graphql.graphql")}
+  python={require("!!code-loader!../../../../../examples/typegraphs/graphql.py")}
+  typescript={require("!!code-loader!../../../../../examples/typegraphs/graphql.ts")}
+  query={require("!!code-loader!./graphql.graphql")}

website/docs/guides/rest/index.mdx Outdated Show resolved Hide resolved
website/docs/reference/runtimes/graphql/index.mdx Outdated Show resolved Hide resolved
website/docs/guides/securing-requests/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
website/docs/concepts/features-overview/index.mdx Outdated Show resolved Hide resolved
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 17

Out of diff range and nitpick comments (1)
website/docs/reference/runtimes/graphql/index.mdx (1)

Line range hint 13-15: Fix the unpaired quotation marks in the require statements.

-  python={require("../../../../../examples/typegraphs/graphql.py")}
-  typescript={require("!!code-loader!../../../../../examples/typegraphs/graphql.ts")}
-  query={require("./graphql.graphql")}
+  python={require("!!code-loader!../../../../../examples/typegraphs/graphql.py")}
+  typescript={require("!!code-loader!../../../../../examples/typegraphs/graphql.ts")}
+  query={require("!!code-loader!./graphql.graphql")}

website/docs/guides/rest/index.mdx Show resolved Hide resolved
website/docs/guides/rest/index.mdx Show resolved Hide resolved
@Yohe-Am Yohe-Am requested a review from destifo May 16, 2024 21:20
michael-0acf4
michael-0acf4 previously approved these changes May 16, 2024
zifeo
zifeo previously approved these changes May 17, 2024
Copy link
Member

@zifeo zifeo left a comment

Choose a reason for hiding this comment

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

Great structure and work!!

Copy link
Contributor

@Natoandro Natoandro left a comment

Choose a reason for hiding this comment

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

Great 👍

Added some comment... Not really relatés to your changes...

destifo
destifo previously approved these changes May 21, 2024
Yohe-Am and others added 6 commits May 22, 2024 14:14
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Signed-off-by: Yohe-Am <56622350+Yohe-Am@users.noreply.github.com>
@Yohe-Am Yohe-Am dismissed stale reviews from destifo, zifeo, and michael-0acf4 via 03e860e May 22, 2024 14:14
@Yohe-Am Yohe-Am force-pushed the docs/features-overview branch from 9be1c56 to 03e860e Compare May 22, 2024 14:14
@Yohe-Am Yohe-Am enabled auto-merge (squash) May 22, 2024 14:26
Copy link
Contributor

@destifo destifo left a comment

Choose a reason for hiding this comment

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

🔥

@Yohe-Am Yohe-Am merged commit b6788a6 into main May 22, 2024
9 checks passed
@Yohe-Am Yohe-Am deleted the docs/features-overview branch May 22, 2024 14:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants