refactor: improve types around dataState and libraryData (#3427)

This commit is contained in:
David Luzar 2021-04-10 19:17:49 +02:00 committed by GitHub
parent c19c8ecd27
commit a7cbe68ae8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 84 additions and 55 deletions

View file

@ -714,6 +714,13 @@ class App extends React.Component<AppProps, AppState> {
initialData = (await this.props.initialData) || null;
} catch (error) {
console.error(error);
initialData = {
appState: {
errorMessage:
error.message ||
"Encountered an error during importing or restoring scene data",
},
};
}
const scene = restore(initialData, null);