Skip to content

Commit

Permalink
fix: some typings warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
pedronauck committed Dec 4, 2018
1 parent a3910b1 commit 4afb87b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
3 changes: 1 addition & 2 deletions packages/load-cfg/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,8 @@ export function load<C = any>(
noCache?: boolean,
deep?: boolean
): C {
let file = {}
const filepath = findup.sync(finds(name))
if (filepath) file = loadFile(filepath, noCache)
const file = filepath ? loadFile(filepath, noCache) : {}

// tslint:disable
return defaultConfig
Expand Down
9 changes: 3 additions & 6 deletions packages/remark-docz/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,8 @@ const mergeNodeWithoutCloseTag = (tree: any, node: any, idx: any) => {
}

// turns `html` nodes into `jsx` nodes
export default () => (tree: any) => {
visit(tree, 'html', visitor)

function visitor(node: any, idx: any): void {
export default () => (tree: any) =>
visit(tree, 'html', (node: any, idx: any): void => {
// check if a node has just open tag
mergeNodeWithoutCloseTag(tree, node, idx)
}
}
})
1 change: 1 addition & 0 deletions tslint.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"extends": ["tslint:latest", "tslint-config-prettier"],
"rules": {
"class-name": false,
"curly": false,
"interface-name": [true, "never-prefix"],
"ordered-imports": false,
Expand Down

0 comments on commit 4afb87b

Please sign in to comment.