Skip to content

Setup for SPA not working #479

@ivanyv

Description

@ivanyv

I ran into some issues\ trying to install the profiler on a Vue app. First, I had to modify the script tag from the example in the README, as it was missing two required data attributes (data-hidden-custom-fields data-html-container="body").

Then I was getting this error in the console: POST http://localhost:3000/mini-profiler-resources/results 404 (Not Found). Which I traced to using "wrong" data-id / data-ids values.

I ended up with this:

<script type="text/javascript" id="mini-profiler"
        src="/mini-profiler-resources/includes.js?v=10da952c710f6abd9f1bd50fe50ed714"
        data-css-url="/mini-profiler-resources/includes.css?v=10da952c710f6abd9f1bd50fe50ed714"
        data-version="10da952c710f6abd9f1bd50fe50ed714" data-path="/mini-profiler-resources/"
        data-horizontal-position="left" data-vertical-position="top"
        data-ids=""
        data-trivial="false" data-children="false" data-max-traces="20" data-controls="false"
        data-total-sql-count="false" data-authorized="true" data-toggle-shortcut="alt+p" data-start-hidden="false"
        data-collapse-results="true" data-html-container="body" data-hidden-custom-fields></script>

I could create a PR for updating the docs if that helps (and above looks right).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions