元问答栏目视频美女
  1. 编程问答
  2. 答案列表
  3. 答案正文

JavaScript 生成随机颜色

你的网站是否需要生成随机颜色?下面一行代码就可以实现。
const generaterandomhexcolor = () =>`#${math.floor(math.random() * 0xffffff).tostring(16)}`console.log(generaterandomhexcolor())。
@mtrang评:0
猜你喜欢