Duplicate start_url field in pwa settings

Chromaniac

Well-known member
So I finally did a test install of 2.2 and was just wondering if it would be possible to add a field for start_url in PWA settings. My board has a makeshift version of manifest file that works well and I prefer the installed icon to load Latest Activity page instead of home page. So the file currently has this line in it: "start_url": "/whats-new/latest-activity",.

From what I have read from other threads, it does seem that I would be able to modify the php file for this but that would probably trigger the file check system. So, it would be nice to have this field in the backend if it's not too much trouble. Thanks!
 
Upvote 0
This suggestion has been closed. Votes are no longer accepted.
So, this is not a template that I can modify. I would have to change a core file. The file seems to be WebManifestRenderer.php... Code is:
Code:
$manifest['start_url'] = $this->app()->router()->buildLink(
            'index',
            null,
            ['_pwa' => 1]
        );

How do I edit it to place /whats-new/latest-activity here :p
 
Code:
$manifest['start_url'] = $this->app()->router()->buildLink(
            '/whats-new/latest-activity',
            null,
            ['_pwa' => 1]
        );

This seems to have worked. One more warning in my backend 😥 . I am not sure how XenForo templating works but this would have been very nice to have as a template! Cheers.
 
Dupe.

 
Right. Hopefully if an addon is developed eventually, it would include other options like color theme included in it. For now, I would manage with the modified core file. :)
 
Necroposting this after facing the same issue. Since my homepage is a Portal plugin, my forums are under /forums. I'd like the app to point there instead of the homepage. Any chance start_url may become configurable in the future?
 
Top Bottom