Skip to content

Commit cd3fab9

Browse files
committed
Updated dox parser to return type.
Updated tests.
1 parent 16d2fb8 commit cd3fab9

File tree

4 files changed

+5
-0
lines changed

4 files changed

+5
-0
lines changed

packages/doxdox-parser-dox/src/index.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ const getRootDirPath = (url) => {};`
3535
path: 'lib/utils/index.js',
3636
methods: expect.arrayContaining([
3737
expect.objectContaining({
38+
type: 'declaration',
3839
fullName: 'findFileInPath(input, fileName)',
3940
name: 'findFileInPath',
4041
params: expect.arrayContaining([
@@ -58,6 +59,7 @@ const getRootDirPath = (url) => {};`
5859
slug: 'lib-utils-index-js-findfileinpath'
5960
}),
6061
expect.objectContaining({
62+
type: 'declaration',
6163
fullName: 'getRootDirPath(url)',
6264
name: 'getRootDirPath',
6365
params: expect.arrayContaining([

packages/doxdox-parser-dox/src/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ export const parseString = async (
4343
}));
4444

4545
return {
46+
type: method.ctx.type,
4647
slug: `${slugify(path)}-${slugify(method.ctx.string)}`,
4748
name: method.ctx.string,
4849
fullName: `${method.ctx.string}(${params

packages/doxdox-renderer-bootstrap/src/index.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ describe('bootstrap', () => {
2424
path: 'directory/index.js',
2525
methods: [
2626
{
27+
type: 'declaration',
2728
slug: 'index-js-methodname',
2829
name: 'methodName',
2930
fullName: 'methodName(param)',

packages/doxdox-renderer-markdown/src/index.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ describe('markdown', () => {
2424
path: 'directory/index.js',
2525
methods: [
2626
{
27+
type: 'declaration',
2728
slug: 'index-js-methodname',
2829
name: 'methodName',
2930
fullName: 'methodName(param)',

0 commit comments

Comments
 (0)