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

Is there any way to include shopify_app concerns conditionally in AuthenticatedController? #153

Open
remy727 opened this issue Nov 20, 2024 · 4 comments

Comments

@remy727
Copy link

remy727 commented Nov 20, 2024

Hello!

I built the embedded app but I also want to let customers access app on the website directly as a standalone app.
Since I have ShopifyApp::EnsureHasSession in AuthenticatedController and controllers are inherited from it, it redirects to login page on a standalone app.

class AuthenticatedController < ApplicationController
  include ShopifyApp::EnsureHasSession
end

Is there any way to include shopify_app concerns in only embedded app?

@matteodepalo
Copy link

Hi @remy727, could you explain more what you're trying to accomplish? Do you want to show an unauthenticated page in the non-embedded app? Things like app bridge and token exchange only work in the embedded version.

@remy727
Copy link
Author

remy727 commented Dec 3, 2024

Hello @matteodepalo
I want to show 2 versions with the same code

  • Embedded app - show in the Shopify admin with App Bridge
  • Non-embedded app - show on app domain when customer tries to access directly on app domain. We used Devise for authentication.

@matteodepalo
Copy link

@remy727 thank you for your feedback, I will talk to the team about this, but this will be a low priority item as non-embedded apps are not officially supported.

@remy727
Copy link
Author

remy727 commented Dec 9, 2024

@matteodepalo, got it. Thank you!

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

No branches or pull requests

2 participants