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/react app/msal/current account #1646

Merged
merged 4 commits into from
Jan 2, 2024
Merged

Conversation

odinr
Copy link
Collaborator

@odinr odinr commented Jan 2, 2024

Why

expose with hooks current account and access token

  • created hooks for accessing current authenticated account
  • created hooks for acquiring token
  • created hooks for acquiring access token
  • created a cookbook for using msal

closes: #1583

note that this is not the same as currentUser i legacy Fusion-API, but the account of which is currently logged on MSAL.

Check off the following:

  • Confirm that I checked changes to branch which I am merging into.

    • I have validated included files
    • My code does not generate new linting warnings
    • My PR is not a duplicate, check existing pr`s
  • Confirm that the I have completed the self-review checklist.

  • Confirm that my changes meet our code of conduct.

Conditional

  • Confirm project selected and category, actual, iteration are set
  • Confirm Milestone selected (if any)

Copy link

changeset-bot bot commented Jan 2, 2024

🦋 Changeset detected

Latest commit: 7e75969

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 20 packages
Name Type
@equinor/fusion-framework-module-msal Patch
@equinor/fusion-framework-react-app Minor
@equinor/fusion-framework-cookbook-app-react-msal Major
@equinor/fusion-framework-app Patch
@equinor/fusion-framework-cli Patch
@equinor/fusion-framework Patch
@equinor/fusion-framework-module-http Patch
@equinor/fusion-framework-module-signalr Patch
@equinor/fusion-framework-module-telemetry Patch
@equinor/fusion-framework-legacy-interopt Major
@equinor/fusion-framework-widget Patch
@equinor/fusion-framework-react Patch
@equinor/fusion-framework-react-components-bookmark Patch
@equinor/fusion-framework-react-components-people-provider Patch
@equinor/fusion-framework-module-service-discovery Patch
@equinor/fusion-framework-module-widget Patch
@equinor/fusion-framework-react-module-http Patch
@equinor/fusion-framework-react-module-signalr Patch
@equinor/fusion-framework-react-module-bookmark Patch
@equinor/fusion-framework-react-module-context Patch

Not sure what this means? Click here to learn what changesets are.

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

@github-actions github-actions bot added 🐞 bug Something isn't working 👨🏻‍🍳 cookbooks 👾 React 📚 documentation Improvements or additions to documentation 🚀 feature New feature or request 🧬 Modules labels Jan 2, 2024
@odinr odinr marked this pull request as ready for review January 2, 2024 14:51
@odinr odinr requested a review from a team as a code owner January 2, 2024 14:51
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
return { token, pending, error };
};

export default useToken;
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ [eslint] <prettier/prettier> reported by reviewdog 🐶
Insert

Suggested change
export default useToken;
export default useToken;

@odinr odinr merged commit 5eab8af into main Jan 2, 2024
6 of 7 checks passed
@odinr odinr deleted the feat/react-app/msal/current-account branch January 2, 2024 15:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 bug Something isn't working 👨🏻‍🍳 cookbooks 📚 documentation Improvements or additions to documentation 🚀 feature New feature or request 🧬 Modules 👾 React
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Missing useCurrentUser hook
1 participant