mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
readme updated
This commit is contained in:
@@ -208,6 +208,9 @@
|
||||
<ItemGroup>
|
||||
<Content Include="globals\Readme.md" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="timer\Readme.md" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)' == 'iOS'">
|
||||
<TypeScriptModuleKind>commonjs</TypeScriptModuleKind>
|
||||
<TypeScriptRemoveComments>True</TypeScriptRemoveComments>
|
||||
|
||||
@@ -13,4 +13,20 @@
|
||||
var intervalId = setInterval(function(){ log("Test"); }, 2000);
|
||||
...
|
||||
clearInterval(intervalId)
|
||||
```
|
||||
OR
|
||||
```js
|
||||
var timer = require("timer");
|
||||
|
||||
timer.setTimeout(function(){ log("Test"); }, 2000);
|
||||
|
||||
var id = timer.setTimeout(function(){ log("Test"); }, 2000);
|
||||
...
|
||||
timer.clearTimeout(id);
|
||||
|
||||
timer.setInterval(function(){ log("Test"); }, 2000);
|
||||
|
||||
var intervalId = timer.setInterval(function(){ log("Test"); }, 2000);
|
||||
...
|
||||
timer.clearInterval(intervalId)
|
||||
```
|
||||
Reference in New Issue
Block a user