Shopfiy custom app links are not working inside shopify iframe kyon147/laravel-shopify package

I am using kyon147/laravel-shopify package which is extending from osiset user. The app was already built on another laravel-shopify package that is abandoned now. I have upgraded the package. I fixed all the reported issues.

The problem I am facing is whenever I click on any of the link of the app that is hosted locally. None of the links work. The screen keeps flashing. When I click on the sidebar of shopify all the links work fine.

I have checked X-frame-options' is also set to false using grep -r 'X-Frame-Options’I tried to Log the session data. The array is empty in that even on homepage but after I use dd inHomeController`. It returns few values. I have cross-checked log file. The network tab has returns success code 302 for app bridge which means there is no problem as it is only redirecting. Only working links are those, which are not embedded in shopify app. The link

<a  class="Polaris-Breadcrumbs__Breadcrumb" href="{{url('/home')}}" data-polaris-unstyled="true">

is not working. But the following link working

<a class="btn btn-lg btn-success" href="https://wyday.com/limelm/signup/" target="_blank" role="button">Sign up on LimeLm</a>

The only difference I found in the Network tab is how the embedded and non-embedding links are redirecting. Following is a non-embedded link

Following embedded this also include the flashing screen

I have added all my links to allowed redirects as well.

I don’t know why the example route isn’t provided with the documentation clearly. I found the solution here, vendor/kyon147/laravel-shopify/src/Macros/TokenRoute.php

Just use URL::tokenRoute(“”) instead

* @example `URL::tokenRoute('orders.view', ['id' => 1]);`
* @example `<a href="{{ URL::tokenRoute('orders.view', ['id' => 1]) }}">Order #1</a>`
* @example `URL::tokenRoute('orders.view', ['id' => 1]);`
* @example `<a href="{{ URL::tokenRoute('orders.view', ['id' => 1]) }}">Order #1</a>`
* @example `URL::tokenRoute('orders.view', ['id' => 1]);`
* @example `<a href="{{ URL::tokenRoute('orders.view', ['id' => 1]) }}">Order #1</a>`

I am using URL::tokenRoute(‘home’) and it works but problem is it reloads app and a placeholder loader from shopify is shown. Is there a way to fix this or to disable this loader?