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

Allow relative paths in reports, for when the path to be published is complex and variable. #244

Closed
juanjol opened this issue Oct 4, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@juanjol
Copy link

juanjol commented Oct 4, 2024

Clear and concise description of the problem

Hi, although this may seem like a duplicate of #201 and #192 , I wanted to comment on my case to see if there is a possible solution that does not involve a massive replacement of the routes.

I'm implementing unlighthouse in a Jenkins process, where we publish the report as a browsable artifact. This means that the report ends up in a complex (multi-level) route that changes with each execution of the job. The routerPrefix option seems like a great solution for fixed urls, but in this case we can't predict the final path in a simple way, so our approach was that the path to the assets should be relative, something like ‘assets/’ or ‘./assets/’, but from what I've seen routerPrefix always ends up adding an slash in front of it.

Is there any way to make the paths relative?

Suggested solution

Add an option in config to allow relative routes, routerRelative maybe?``

Alternative

No response

Additional context

No response

@juanjol juanjol added the enhancement New feature or request label Oct 4, 2024
@harlan-zw
Copy link
Owner

Hi, if you provide no routerPrefix is will now attempt to load anything relative form the path its served.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants