nice-modal-react
nice-modal-react copied to clipboard
Can the show method intelligently prompts those parameters?
We create and register a pop -up window
type MProps = {
name: string,
age: number,
};
const M = NiceModal.create<MProps>(({ name, age }) => (
<div>
{name}-{age}
</div>
));
NiceModal.register('M_MODAL', M);
When using it, you cannot intelligently indicate the parameters you need to pass
NiceModal.show('M_MODAL', {});