Skip to content

Why are there two divs with the same id of app? #7

Open
@aysiscore

Description

@aysiscore

In public/index.html there is a <div id="app"></div>

And then once again in src/App.vue

When the app is rendered to the browser there are now two div elements of the same id which is not HTML5 compliant code. I end up with:

<div id="app" data-v-app="">
<div id="app">
<!-- router content here -->
</div>
</div>

Why is this so and how can we change it so that the ids are unique for each div.

Activity

added a commit that references this issue on Aug 23, 2023

fix moduslabs#7, which contains 2 div element with same id;

ce10c32
zhangzhuang15

zhangzhuang15 commented on Aug 23, 2023

@zhangzhuang15

I fix this issue on my own repo branch (https://github.com/zhangzhuang15/vue3-example-ssr/tree/jasonzhang-feature), you can take a try.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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

      Why are there two divs with the same id of app? · Issue #7 · moduslabs/vue3-example-ssr