盛夏的果实 发表于 2021-7-13 18:03:41

Node.js:创建一个随机的UUID

  文档:https://www.npmjs.com/package/uuid
  安装
npm i uuid
  示例
const { v4: uuidv4 } = require("uuid");

console.log(uuidv4());
// 92b8a6bd-f1fd-4b52-b8a0-6178a0e76828

  
文档来源:51CTO技术博客https://blog.51cto.com/u_13567403/3039803
页: [1]
查看完整版本: Node.js:创建一个随机的UUID