ProsperWorks/pw-app-sdk

View on GitHub
src/index.ts

Summary

Maintainability
A
2 hrs
Test Coverage
A
98%

PWSDK has 28 functions (exceeds 20 allowed). Consider refactoring.
Wontfix

export default class PWSDK {
  public static init() {
    const parentOrigin = getParameterByName('origin');
    const instanceId = getParameterByName('instanceId');
    const options: ISdkInitOptions = {
Severity: Minor
Found in src/index.ts - About 3 hrs to fix

File index.ts has 277 lines of code (exceeds 250 allowed). Consider refactoring.
Open

import { version } from '../package.json';
import {
  createEntityDataGenerator,
  logActivityDataGenerator,
  relateEntityDataGenerator,
Severity: Minor
Found in src/index.ts - About 2 hrs to fix

Array type using 'Array<t>' is forbidden. Use 'T[]' instead.</t>
Open

  private deferredQueues: { [name: string]: Array<Deferred<IMessageData>> } = {};
Severity: Minor
Found in src/index.ts by tslint

Rule: array-type

Requires using either 'T[]' or 'Array<t>' for arrays.</t>

Notes
  • TypeScript Only
  • Has Fix

Config

One of the following arguments must be provided:

  • "array" enforces use of T[] for all types T.
  • "generic" enforces use of Array<T> for all types T.
  • "array-simple" enforces use of T[] if T is a simple type (primitive or type reference).
Examples
"array-type": true,array
"array-type": true,generic
"array-type": true,array-simple
Schema
{
  "type": "string",
  "enum": [
    "array",
    "generic",
    "array-simple"
  ]
}

For more information see this page.

Array type using 'Array<t>' is forbidden. Use 'T[]' instead.</t>
Open

  private events: { [name: string]: Array<() => any> } = {};
Severity: Minor
Found in src/index.ts by tslint

Rule: array-type

Requires using either 'T[]' or 'Array<t>' for arrays.</t>

Notes
  • TypeScript Only
  • Has Fix

Config

One of the following arguments must be provided:

  • "array" enforces use of T[] for all types T.
  • "generic" enforces use of Array<T> for all types T.
  • "array-simple" enforces use of T[] if T is a simple type (primitive or type reference).
Examples
"array-type": true,array
"array-type": true,generic
"array-type": true,array-simple
Schema
{
  "type": "string",
  "enum": [
    "array",
    "generic",
    "array-simple"
  ]
}

For more information see this page.

There are no issues that match your filters.

Category
Status