Skip to content

Commit

Permalink
add subcateogry
Browse files Browse the repository at this point in the history
  • Loading branch information
wojtek-krysiak committed Mar 7, 2020
1 parent de549e1 commit 9460e36
Show file tree
Hide file tree
Showing 14 changed files with 3,548 additions and 3,332 deletions.
2 changes: 1 addition & 1 deletion bundler.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ module.exports = function bundle (Components, out, config) {
fs.writeFileSync(entry, entryFile)
console.log('Bundling components')
const outDist = path.join(out, 'build')
const cmd = `parcel build ${entry} --out-dir ${outDist}`
const cmd = `NODE_ENV=development parcel build ${entry} --out-dir ${outDist}`
console.log(`running: ${cmd}`)
try {
execSync(cmd)
Expand Down
4 changes: 4 additions & 0 deletions category.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ exports.handlers = {
if (categoryTag) {
doclet.category = categoryTag.value
}
const subCategoryTag = doclet.tags.find(tag => tag.title === 'subcategory')
if (subCategoryTag) {
doclet.subCategory = subCategoryTag.value
}
}
}
}
5 changes: 5 additions & 0 deletions fixtures/typescript/static-member.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ class ClassName {
* Static member
*/
static somethingIs: number
someMethod() {
const a = {g: 1}
return a?.g
}
}
`

Expand Down
26 changes: 26 additions & 0 deletions fixtures/typescript/type6.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
const input =
`
/**
* Some comment
*/
export type RecordActionAPIParams = AxiosRequestConfig & {
/**
* Id of a record taken from {@link RecordJSON}
*/
recordId: string;
}
`

const outputs = [
'/**',
'* Some comment',
'* @typedef {object} RecordActionAPIParams',
'* @property {string} recordId Id of a record taken from {@link RecordJSON}',
'*/',
]


module.exports = {
input,
outputs,
}
43 changes: 43 additions & 0 deletions fixtures/typescript/type7.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
const input =
`
/**
* @alias BuildHandlerOptions
*
* @memberof module:admin-bro-firebase-functions
*/
export type BuildHandlerOptions = {
/** Function region */
region: string;
/** Optional before async hook which can be used to initialize database */
before?: () => Promise<any>;
/**
* custom authentication options
*/
auth?: {
/**
* secret which is used to encrypt the session cookie
*/
secret: string;
/**
* authenticate function
*/
authenticate?: (
email: string,
password: string) => Promise<CurrentAdmin | null> | CurrentAdmin | null;
};
}
`

const outputs = [
'/**',
'* @property {object} [auth] custom authentication options',
'* @property {string} auth.secret secret which is used to encrypt the session cookie',
'* @property {function} [auth.authenticate] authenticate function',
'*/',
]


module.exports = {
input,
outputs,
}
Loading

0 comments on commit 9460e36

Please sign in to comment.