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

feat: add useRuntimeContext api data structure #6496

Merged
merged 1 commit into from
Nov 5, 2024
Merged

Conversation

zllkjc
Copy link
Member

@zllkjc zllkjc commented Nov 5, 2024

Summary

  1. add context field in useRuntimeContext return value, the same as inhouse framework.
  2. add TSSRBaseContext for the context field.
  3. remove useless export BaseRuntimeContext.
  4. pickedContext should not be assigned extra field, so we remove [key: string]: any in TRuntimeContext, and use TRuntimeContext instead BaseTRuntimeContext.

Related Links

Checklist

  • I have added changeset via pnpm run change.
  • I have updated the documentation.
  • I have added tests to cover my changes.

Copy link

changeset-bot bot commented Nov 5, 2024

⚠️ No Changeset found

Latest commit: d04128f

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

netlify bot commented Nov 5, 2024

Deploy Preview for modernjs-byted ready!

Name Link
🔨 Latest commit d04128f
🔍 Latest deploy log https://app.netlify.com/sites/modernjs-byted/deploys/672a1708ca8de300080b9c4e
😎 Deploy Preview https://deploy-preview-6496--modernjs-byted.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 75 (🔴 down 4 from production)
Accessibility: 90 (no change from production)
Best Practices: 100 (no change from production)
SEO: 91 (no change from production)
PWA: -
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify site configuration.

@zllkjc zllkjc changed the title WIP feat: add useRuntimeContext api data structure feat: add useRuntimeContext api data structure Nov 5, 2024
@caohuilin caohuilin merged commit 8406503 into main Nov 5, 2024
11 checks passed
@caohuilin caohuilin deleted the feat/runtime-context branch November 5, 2024 14:54
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.

2 participants