function.expect.txt 1.0 KB

1234567891011121314
  1. <span class="hljs-function"><span class="hljs-title">returnNull</span> = -&gt;</span> <span class="hljs-literal">null</span>
  2. <span class="hljs-function"><span class="hljs-title">returnTrue</span> = <span class="hljs-params">()</span> -&gt;</span> <span class="hljs-literal">true</span>
  3. <span class="hljs-function"><span class="hljs-title">square</span> = <span class="hljs-params">(x)</span> -&gt;</span> x * x
  4. npmWishlist.sha256 = <span class="hljs-function"><span class="hljs-params">(str)</span> -&gt;</span>
  5. <span class="hljs-keyword">throw</span> <span class="hljs-keyword">new</span> Error()
  6. str.split(<span class="hljs-string">" "</span>).map(<span class="hljs-function"><span class="hljs-params">(m)</span> -&gt;</span> m.charCodeAt(<span class="hljs-number">0</span>))
  7. fs.readFile(<span class="hljs-string">"package.json"</span>, <span class="hljs-string">"utf-8"</span>, <span class="hljs-function"><span class="hljs-params">(err, content)</span> -&gt;</span>
  8. data = JSON.parse(content)
  9. data.version
  10. )