Skip to content
This repository was archived by the owner on Oct 1, 2025. It is now read-only.
This repository was archived by the owner on Oct 1, 2025. It is now read-only.

Updating to v2.x: meta.inject() in SSR HTML is undefined #391

@ghost

Description

I've read the "Migration Guide" parts of the changelogs, but couldn't find anything that points me in the right direction:

When I upgrade to version 2.x, the server side rendering of my app fails.
1.) I get the warning "This vue app/component has no vue-meta configuration"
2.) I get the Error: "TypeError: Cannot read property 'title' of undefined" (this comes from my HTML file where I use {{{meta.inject().title.text()}}} - meta.inject() seems to be undefined.

This is a part of my entry_server.js:

export default context => {
	return new Promise((resolve, reject) => {
		createApp().then(data => {
			context.meta = data.app.$meta();
...

Is there anything else that changed and needs to be modified?
Unfortunately it's not easy to prepare a minimal app to isolate the error, but perhaps others have had this problem when upgrading their SSR app, too and can give me a hint.

Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions