Fix ui render call, improve error message (#294)
This commit is contained in:
parent
735bd983a5
commit
ce79d3cd95
2 changed files with 3 additions and 2 deletions
|
@ -120,7 +120,8 @@ export default class Project {
|
|||
`while you are using @theatre/core along with @theatre/studio. But since @theatre/studio ` +
|
||||
`is not loaded, the state of project "${id}" will be empty.\n\n` +
|
||||
`To fix this, you need to add @theatre/studio into the bundle and export ` +
|
||||
`the project's state. Learn how to do that at https://docs.theatrejs.com/in-depth/#exporting`,
|
||||
`the project's state. Learn how to do that at https://docs.theatrejs.com/in-depth/#exporting\n` +
|
||||
`If you are using a framework like Next.js, this error may be caused by running Theatre on the server side.`,
|
||||
)
|
||||
}
|
||||
}, 1000)
|
||||
|
|
|
@ -148,7 +148,7 @@ export class Studio {
|
|||
|
||||
this._initializedDeferred.resolve()
|
||||
|
||||
if (process.env.NODE_ENV !== 'test') {
|
||||
if (process.env.NODE_ENV !== 'test' && this.ui) {
|
||||
this.ui.render()
|
||||
checkForUpdates()
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue