Progress
This commit is contained in:
@@ -15,4 +15,22 @@ function Prompt(props) {
|
||||
)
|
||||
}
|
||||
|
||||
export default Prompt
|
||||
export default Prompt
|
||||
|
||||
|
||||
// Potential new solution:
|
||||
// import { useBlocker } from 'react-router-dom';
|
||||
//
|
||||
// function Prompt({ when, message }) {
|
||||
// useBlocker((transition) => {
|
||||
// if (when) {
|
||||
// transition.retry();
|
||||
// return !window.confirm(message);
|
||||
// }
|
||||
// return false;
|
||||
// }, when);
|
||||
//
|
||||
// return null;
|
||||
// }
|
||||
//
|
||||
// export default Prompt;
|
||||
Reference in New Issue
Block a user