fix: #393, ensures preview button gets up to date data
This commit is contained in:
@@ -48,6 +48,12 @@ const EditView: React.FC<IndexProps> = (props) => {
|
||||
} else {
|
||||
const state = await buildStateFromSchema(fields, json.doc);
|
||||
setInitialState(state);
|
||||
|
||||
history.push({
|
||||
state: {
|
||||
data: json.doc,
|
||||
},
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user