Skip to content
This repository was archived by the owner on Apr 27, 2026. It is now read-only.

Commit f6b800f

Browse files
author
Craigory Coppola
committed
fix(nxdoc): nxdocs fails to run if any file does not have getting started text
1 parent e1b58a6 commit f6b800f

5 files changed

Lines changed: 9 additions & 60 deletions

File tree

docs/core/executors/format.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ Formats and lints a project using the dotnet-format tool
2424

2525
### diagnostics
2626

27-
-
2827
- (string): A space separated list of diagnostic ids to use as a filter when fixing code style or 3rd party analyzers.
2928
- (array): A list of diagnostic ids to use as a filter when fixing code style or 3rd party analyzers.
3029

docs/typescript/index.md

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -4,33 +4,4 @@ sidebar_position: 0
44
slug: /typescript/
55
---
66

7-
# Getting Started
8-
9-
> The features for this package are not yet implemented. This package will be used to generate typescript interfaces given a web-api project in the future.
10-
11-
## Prerequisites
12-
13-
- Have an existing nx workspace. For creating this, see [nrwl's documentation](https://nx.dev/latest/angular/getting-started/nx-setup).
14-
- .NET SDK is installed, and `dotnet` is available on the path. For help on this, see [Microsoft's documentation](https://dotnet.microsoft.com/learn/dotnet/hello-world-tutorial/install)
15-
16-
## Installation
17-
18-
### NPM
19-
20-
```shell
21-
npm i --save-dev @nx-dotnet/typescript
22-
```
23-
24-
### PNPM
25-
26-
```shell
27-
pnpm i --save-dev @nx-dotnet/typescript
28-
```
29-
30-
### Yarn
31-
32-
```shell
33-
yarn add --dev @nx-dotnet/typescript
34-
```
35-
367
# API Reference

packages/nxdoc/src/generators/generate-docs/generator.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,15 @@ export default async function (host: Tree, options: Schema) {
3030
}[] = [];
3131

3232
projects.forEach((project) => {
33-
const gettingStartedFile = options.gettingStartedFile.replace(
33+
let gettingStartedFile: string | null = options.gettingStartedFile.replace(
3434
'<src>',
3535
project.root,
3636
);
3737

38+
gettingStartedFile = host.exists(gettingStartedFile)
39+
? gettingStartedFile
40+
: null;
41+
3842
const generatorsCollection: GeneratorsCollection = project.generators
3943
? readJson<GeneratorsCollection>(host, `${project.root}/generators.json`)
4044
: ({} as GeneratorsCollection);
@@ -67,7 +71,7 @@ export default async function (host: Tree, options: Schema) {
6771
generators,
6872
executors,
6973
underscore: '_',
70-
gettingStartedMd: options.gettingStartedFile
74+
gettingStartedMd: gettingStartedFile
7175
? readFileSync(gettingStartedFile).toString()
7276
: '',
7377
frontMatter: options.skipFrontMatter

packages/nxdoc/src/generators/generate-docs/templates/detail/__generatorFileName__.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@
1212

1313
### <%- (schema.required?.includes?.(property)) ? `<span className="required">${property}</span>` : property %>
1414

15-
- <% if (!config.oneOf) { %>(<%=config.type%>): <%= config.description %>
16-
<%} else { config.oneOf.forEach(x => {%>
15+
<% if (!config.oneOf) { %>- (<%=config.type%>): <%= config.description %>
16+
<%} else { config.oneOf.forEach(x => {%>
17+
1718
- (<%= x.type %>): <%=x.description%>
1819
<% })}})} %>

packages/typescript/README.md

Lines changed: 0 additions & 26 deletions
This file was deleted.

0 commit comments

Comments
 (0)