typedoc

TypeDoc complains “Cannot find module”

空扰寡人 提交于 2021-01-22 06:36:09
问题 I have a Typsecript based react app. It works fine but I want to add TypeDoc (think JSDoc for Typescript) to the mix. After installing it I run this from the command line (only processing a single file as I test this): typedoc --module commonjs --jsx react --out ../docs/ ./src/components/404/404.tsx and I get an error: Error: /path/to/project/src/components/404/404.tsx(0) Cannot find module 'react'. React is, in fact, installed. I have tried running TypeDoc installed globally and locally and

TypeDoc complains “Cannot find module”

人盡茶涼 提交于 2021-01-22 06:35:27
问题 I have a Typsecript based react app. It works fine but I want to add TypeDoc (think JSDoc for Typescript) to the mix. After installing it I run this from the command line (only processing a single file as I test this): typedoc --module commonjs --jsx react --out ../docs/ ./src/components/404/404.tsx and I get an error: Error: /path/to/project/src/components/404/404.tsx(0) Cannot find module 'react'. React is, in fact, installed. I have tried running TypeDoc installed globally and locally and

publishing a typescript library on npm: exported symbols, modules

柔情痞子 提交于 2019-12-23 16:14:21
问题 I'm writing a typescript library which I intend to publish on npm . It is meant to run in node only, never in the browser. It will make sense to use the library only from typescript (I'm not expecting any Javascript users). I have trouble finding guides how to publish typescript-for-typescript libraries on npm (also, these things seem to be changing rapidly in the typescript world). Should I wrap all my code in a module ? (I don't feel the need for modules in the library itself, it's

Linking to external library documentation with TypeDoc

对着背影说爱祢 提交于 2019-12-12 11:22:24
问题 I have a TypeScript project, and I'm using TypeDoc to generate documentation for it. In my project I am using an external library that has its own existing documentation. In the TypeDoc output for my project I want to link the reader to the documentation for the external library without having to manually insert a URL. The closest I've come to a solution is placing double brackets in the code comments around what I want to link to, like this: /** I want to link to something called [[Foo]] */

TypeDoc can not find Angular2 modules

情到浓时终转凉″ 提交于 2019-12-10 13:30:03
问题 I am trying to generate doc files by using TypeDoc. When I run TypeDoc with the follwing command: /node_modules/.bin/typedoc --module system --target ES5 --exclude *.spec.ts* --experimentalDecorators --out typedoc app/ --ignoreCompilerErrors It gives as output: Using TypeScript 1.6.2 from /development/node_modules/typedoc/node_modules/typescript/lib Error: /development/app/angular2/app.ts(1) Cannot find module 'angular2/core'. Error: /development/app/angular2/app.ts(2) Cannot find module