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

How to customize the harPreview #132

Open
syndy1989 opened this issue Oct 31, 2018 · 6 comments
Open

How to customize the harPreview #132

syndy1989 opened this issue Oct 31, 2018 · 6 comments

Comments

@syndy1989
Copy link

I embedded harviewer in to my html page to load the har files from my local machine. It works fine. but when i expand the resources and navigate through the tabs (Response, Highlighted, JSON) it just hangs and my html page is getting refreshed and at times become unresponsive. Is there any way to disable the ability to expand the resources.

Please find the below screenshot for desired output:
error

Any advise on how to achieve this would be really helpful. Thanks in advance.

@gitgrimbo
Copy link
Collaborator

The primary issue here is customising the preview so that the resource rows are not expandable, I can look into this.


But you also include a separate issue which sounds like a bug. However -

I don't see the "Response, Highlighted, JSON" tabs hanging when I try this, see:

#130 (comment)

Can you confirm that using the http://gitgrimbo.github.io/harviewer/issue-130/examples/embed.html page with your HAR file causes an error, because I can't see such an error (the screenshot accompanying the comment above shows the embed page working normally with your HAR file, served from localhost).

@syndy1989
Copy link
Author

When we have less number of network request it works fine . I tried with some sample url which has 310 n/w request. Please find the below screenshot. the page just hangs
unresponsive

so all i need is to remove the response tab. Any advise on how to do that would be helpful. Thanks

@gitgrimbo
Copy link
Collaborator

gitgrimbo commented Oct 31, 2018

I am using your har.har from #130 which has 311 requests. And using Firefox (63.0) as I assume that is the browser you are using.

I can see a slowdown when using the "Highlighted" tab because SyntaxHighlighter (used in HAR Viewer) is quite slow for large files, e.g. the large show_ads_impl.js file (below I have clicked on the "Highlighted" tab, but it takes a long time, so Firefox has shown the warning - this is also slow in Chrome):

image

If any other tabs give you a slowdown then let me know, otherwise the "Highlighted" tab is known to slow down for large resources.

A previous fix for #81 was to have a separate "Highlighted" tab so that you can choose if you want to view the resource with syntax highlighting. If you don't want a slowdown, then the only advice at the moment is to not click on the "Highlighted" tab.

The "Response" tab should not be slow. If it is, then please raise a separate issue with an example.

@syndy1989
Copy link
Author

I replaced the css and js files as suggested. It is working perfectly. Thankyou

@gitgrimbo
Copy link
Collaborator

Cool, will leave this open for now as a general issue for customising the preview.

A new issue has been raised to track syntax-highlighting slowdowns, #135.

@gitgrimbo
Copy link
Collaborator

See #137 for new syntax highlighting.

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