Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Vue app context not the same when hydrating at client side.聽#207

Copy link
Copy link
@joesonw

Description

@joesonw
Issue body actions

Description 馃摉

I was trying to use vue-i18n with client:load hydration, I cannot get it work because it keeps telling me i18n is not installed to the app.

So I tried to print out getCurrentInstance() within the component, it turns out that at each component rendering (there is a list of them), instance.appContext.app is different, its uid is never 0 (which is the one from app.ts).
.
Was I doing something wrong? Or is this intended?

Reproduction 馃悶

print out getCurrentInstance() in any client hydrated component.

Dependencies Info

Run npx iles info and pnpm list (or npm list) and provide the output:


dependencies:
@faker-js/faker 7.6.0
******
******
******
******
dayjs 1.11.6
isomorphic-fetch 3.0.0
reflect-metadata 0.1.13
vue-i18n 9.2.2

devDependencies:
@types/isomorphic-fetch 0.0.36                          body-parser 1.20.0                                      postcss-discard-comments 5.1.2                          
******             concurrently 7.4.0                                      postcss-use 3.0.0                                       
******     cors 2.8.5                                              sass 1.55.0                                             
******   express 4.18.1                                          typescript 4.8.4                                        
******                  iles 0.8.5                                              vite 3.2.4                                              
******            json-graphql-server 2.3.2                               vitest 0.23.2                                           
@vitejs/plugin-vue 3.1.2                                postcss 8.4.17                                          vue 3.2.39                                              
autoprefixer 10.4.12                                    postcss-clean 1.2.2                                     vue-tsc 0.38.9     

Logs 馃摐

If not providing a reproduction:

Output

Run DEBUG=iles:* npm run dev or DEBUG=iles:* npm run build and provide the output:


Screenshots 馃摲

Provide console or browser screenshots of the problem.

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.