You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

649 B

其他提示类型

  • order: 1

包括成功、失败、警告。


import { message, Button } from 'antd';

const success = function () {
  message.success('这是一条成功提示');
};

const error = function () {
  message.error('这是一条报错提示');
};

const warn = function () {
  message.warn('这是一条警告提示');
};

ReactDOM.render(<div>
  <Button onClick={success}>显示成功提示</Button>
  <Button onClick={error}>显示报错提示</Button>
  <Button onClick={warn}>显示警告提示</Button>
</div>, mountNode);