🔥码云GVP开源项目 12k star Uniapp+ElementUI 功能强大 支持多语言、二开方便! 广告
## delay + [link](./delay "Link to this entry.") + [source](https://github.com/lodash/lodash/blob/4.5.0正式版/lodash.src.js#L8773 "View in source.") + [npm](https://www.npmjs.com/package/lodash.delay "See the npm package.") ``` _.delay(func, wait, [args]) ``` 延迟 `wait` 毫秒后调用 `func`。 任何附加的参数会传入到 `func`。 ### 参数 1. func (Function) 要延迟的函数 2. wait (number) 要延迟的毫秒数 3. [args] (...*) 会在调用时传入到 `func` 的参数 ### 返回值 (number) 返回计时器 id ### 示例 ``` _.delay(function(text) { console.log(text); }, 1000, 'later'); // => 一秒后输出 'later'。 ```