Coder Social home page Coder Social logo

Comments (6)

krisztianb avatar krisztianb commented on July 22, 2024 1

So you want the documentation of several types to be in one file and not one file per type, right? If so then this is not the goal of this plugin.

from typedoc-plugin-merge-modules.

krisztianb avatar krisztianb commented on July 22, 2024

Hi. This plugin merges modules. I haven't used TypeDoc to document JS files yet. Didn't know that works.

I'm a bit confused by your example. Where is your namespace and interface? What would be your expected output?

from typedoc-plugin-merge-modules.

jackens avatar jackens commented on July 22, 2024

TypeScript works quite well with JavaScript files, and if they have JSDoc blocks in addition, it generates .d.ts files that TypeDoc can turn into quite nice documentation :)

I would expect Type3 to be in README.md, just like Type4 (they're actually the same definitions). Likewise with Type5, which should be merged into README.md.

The plugin should merge the contents of modules and interfaces directories.

from typedoc-plugin-merge-modules.

jackens avatar jackens commented on July 22, 2024

README.md:

# issue

Some module.

## Namespaces

- [Type5](modules/Type5.md)

## Interfaces

- [Type3](interfaces/Type3.md)

## Type aliases

### Type1

Ƭ **Type1**<\>: <\>(`one`: `number`, `two`: `number`) => `number`

#### Type declaration

▸ <\>(`one`, `two`): `number`

##### Parameters

| Name  | Type     |
|:------|:---------|
| `one` | `number` |
| `two` | `number` |

##### Returns

`number`

___

### Type2

Ƭ **Type2**<\>: (`one`: `number`, `two`: `number`) => `number`

#### Type declaration

▸ (`one`, `two`): `number`

Some type 2.

##### Parameters

| Name  | Type     |
|:------|:---------|
| `one` | `number` |
| `two` | `number` |

##### Returns

`number`

#### Defined in

file.js:19

___

### Type4

Ƭ **Type4**<\>: `Object`

Some type 4.

#### Type declaration

| Name  | Type     |
|:------|:---------|
| `one` | `number` |
| `two` | `number` |

#### Defined in

file.js:38

## Variables

### Type5`Const` **Type5**: typeof [`Type5`](README.md#type5) = `{}`

Some type 5.

This block will be placed in the `modules/Type5.md` file
instead of the `README.md` file.

#### Defined in

file.js:49

interfaces/Type3.md:

# Interface: Type3<\>

Some type 3.

## Properties

### one**one**: `number`

property #1

#### Defined in

file.js:30

___

### two**two**: `number`

property #2

#### Defined in

file.js:31

modules/Type5.md:

# Namespace: Type5

## Variables

### answer**answer**: `number`

## Functions

### id**id**(`n`): `number`

#### Parameters

| Name | Type     |
|:-----|:---------|
| `n`  | `number` |

#### Returns

`number`

#### Defined in

file.js:56

from typedoc-plugin-merge-modules.

krisztianb avatar krisztianb commented on July 22, 2024

I'm not sure I can follow you there.

This plugin is meant to remove the extra module layer that TypeDoc creates. A module is normally a file which contains something that you want to have documented. The plugin moves all the documented things into the project but doesn't move all documented things into one file which you seem to be looking for here.

from typedoc-plugin-merge-modules.

jackens avatar jackens commented on July 22, 2024

I assumed that the plugin that merges the content of modules should also merge the content of a single module/file (src/file.js from my example). Feel free to close the issue if I am wrong. Thank you for your replies!

from typedoc-plugin-merge-modules.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.