Kyon147 / laravel-shopify

A full-featured Laravel package for aiding in Shopify App development
MIT License
336 stars 99 forks source link

App not loaded on navigation to next page #196

Closed sandeshpaudyal closed 11 months ago

sandeshpaudyal commented 11 months ago

The app is loading when we open the app. But when we navigate to different routes, the app does not load and we also donot have any error log on laravel.log and also on console.

Route::get('/',[HomeController::class,'index'])->middleware(['verify.shopify'])->name('home'); This route is working

Route::get('/products',[ProductController::class,'index'])->middleware(['verify.shopify'])->name('products'); On this route, the app doesnot load. I have tried to log on controller too.

ProductController

class ProductController extends Controller { public function index() { $shop = Auth::user(); $shopDomain = Auth::user()->name; $query = $this->generateQuery('10'); // var_dump(json_encode($query)); $result = $shop->api()->graph($query); return view('product')->with('data', $result['body']); } }

View : product

Product page

Kyon147 commented 11 months ago

You are not using the tokenRedirect helpers. Please read the wiki https://github.com/Kyon147/laravel-shopify/wiki/Authentication-Process