Skip to content

Only refers to a type, but is being used as a value here. #870

Closed
@alexrepetskyi

Description

@alexrepetskyi

Hi, Can you help me? I tried to use it from nodejs script, but I have error.

const path = require('path');
const { Application } = require('typedoc');

const app = new Application({ name: 'PCD' });
const module1 = path.join(__dirname, '../example/module1.ts');
const docs = path.join(__dirname, '../../docs');

app.generateDocs([module1], docs);
Error: /Users/aleksandr/projects/PlanoCustom-Default/node_modules/@types/node/index.d.ts(608)
 'Symbol' only refers to a type, but is being used as a value here.
Error: /Users/aleksandr/projects/PlanoCustom-Default/node_modules/@types/node/index.d.ts(2640)
 'Symbol' only refers to a type, but is being used as a value here.
Error: /Users/aleksandr/projects/PlanoCustom-Default/node_modules/@types/node/index.d.ts(6351)
 Class 'Readable' incorrectly implements interface 'ReadableStream'.
  Property 'pipe' is missing in type 'Readable'.
Error: /Users/aleksandr/projects/PlanoCustom-Default/node_modules/@types/node/index.d.ts(6351)
 'Readable' is referenced directly or indirectly in its own base expression.
Error: /Users/aleksandr/projects/PlanoCustom-Default/node_modules/@types/node/index.d.ts(6427)
 'Symbol' only refers to a type, but is being used as a value here.
Error: /Users/aleksandr/projects/PlanoCustom-Default/node_modules/@types/node/index.d.ts(6526)
 Interface 'DuplexOptions' incorrectly extends interface 'WritableOptions'.
  Types of property 'write' are incompatible.
    Type '(this: Duplex, chunk: any, encoding: string, callback: (error?: Error) => void) => void' is not assignable to type '(this: Writable, chunk: any, encoding: string, callback: (error?: Error) => void) => void'.
      The 'this' types of each signature are incompatible.
        Type 'Writable' is not assignable to type 'Duplex'.
          Property 'readable' is missing in type 'Writable'.
Error: /Users/aleksandr/projects/PlanoCustom-Default/node_modules/@types/node/index.d.ts(6538)
 Class 'Duplex' incorrectly implements class 'Writable'. Did you mean to extend 'Writable' and inherit its members as a subclass?
  Property 'pipe' is missing in type 'Duplex'.
Error: /Users/aleksandr/projects/PlanoCustom-Default/src/example/module1.ts(24)
 Cannot use imports, exports, or module augmentations when '--module' is 'none'.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions