Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ var analyze = require( '@stdlib/_tools/static-analysis/js/lloc-file-list' );
Calculates [logical lines of code][@stdlib/_tools/static-analysis/js/incr/lloc] (LLOC) for a list of JavaScript files.

```javascript
```markdown
```text
var files = [ './beep.js', './boop.js' ];

analyze( files, clbk );
Expand All @@ -66,6 +68,8 @@ The function accepts the following `options`:
By default, the function performs a cumulative analysis. To return a LLOC calculation for each file in `files`, set the `cumulative` option to `false`.

```javascript
```markdown
```text
var files = [ './beep.js', './boop.js' ];

var opts = {
Expand All @@ -89,6 +93,8 @@ function clbk( error, results ) {
Synchronously calculates [logical lines of code][@stdlib/_tools/static-analysis/js/incr/lloc] (LLOC) for a list of JavaScript files.

```javascript
```markdown
```text
var files = [ './beep.js', './boop.js' ];

var results = analyze.sync( files );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ limitations under the License.
var analyze = require( '@stdlib/_tools/static-analysis/js/sloc-file-list' );
```

<a name="analyze-async"></a>
#### analyze-async

#### analyze( files, \[options,] clbk )

Expand Down Expand Up @@ -122,9 +122,9 @@ The function accepts the same `options` as [`analyze()`](#analyze-async) above.

## Examples

<!-- eslint no-undef: "error" -->

```javascript
/* eslint no-undef: "error" */

var join = require( 'path' ).join;
var analyze = require( '@stdlib/_tools/static-analysis/js/sloc-file-list' );

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ var analyze = require( '@stdlib/_tools/static-analysis/js/summarize-file-list' )
Performs a static [summary analysis][@stdlib/_tools/static-analysis/js/incr/program-summary] for a list of JavaScript files.

```javascript
```markdown
```text
var files = [ './beep.js', './boop.js' ];

analyze( files, clbk );
Expand All @@ -66,6 +68,8 @@ The function accepts the following `options`:
By default, the function performs a cumulative static [summary analysis][@stdlib/_tools/static-analysis/js/incr/program-summary]. To return a separate [program summary][@stdlib/_tools/static-analysis/js/program-summary] for each file in `files`, set the `cumulative` option to `false`.

```javascript
```markdown
```text
var files = [ './beep.js', './boop.js' ];

var opts = {
Expand All @@ -86,6 +90,8 @@ function clbk( error, results ) {
Synchronously performs a static [summary analysis][@stdlib/_tools/static-analysis/js/incr/program-summary] for a list of JavaScript files.

```javascript
```markdown
```text
var files = [ './beep.js', './boop.js' ];

var results = analyze.sync( files );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@
* limitations under the License.
*/

/* eslint-disable no-new-wrappers */

'use strict';

var Number = require( '@stdlib/number/ctor' );
Expand Down
2 changes: 1 addition & 1 deletion lib/node_modules/@stdlib/blas/base/zscal/examples/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
var discreteUniform = require( '@stdlib/random/base/discrete-uniform' );
var filledarrayBy = require( '@stdlib/array/filled-by' );
var Complex128 = require( '@stdlib/complex/float64/ctor' );
var zscal = require( '@stdlib/blas/base/zscal' );
var zscal = require( "./../lib" );

Check failure on line 24 in lib/node_modules/@stdlib/blas/base/zscal/examples/index.js

View workflow job for this annotation

GitHub Actions / Lint Changed Files

Strings must use singlequote

function rand() {
return new Complex128( discreteUniform( 0, 10 ), discreteUniform( -5, 5 ) );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@ function render( ctx ) {
transform = tickTransform( ctx._orientation, ctx._scale );

debug( 'Rendering ticks...' );
out = new Array( values.length );
out = [];
for ( i = 0; i < values.length; i++ ) {
debug( 'Rendering tick %d with value %s...', i, values[i] );
out[ i ] = tick( ctx, values[i], transform );
out.push(tick( ctx, values[i], transform ));
}
debug( 'Finished rendering ticks.' );
return out;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ var obj = {
'beep': 'boop'
};

throw obj; // eslint-disable-line no-throw-literal
throw obj;
Loading