mirror of https://github.com/lukechilds/rollup.git
4 changed files with 6 additions and 42 deletions
@ -1,6 +1,6 @@ |
|||||
export default function isFunctionDeclaration ( node ) { |
export default function isFunctionDeclaration ( node ) { |
||||
if ( !node ) return false; |
if ( !node ) return false; |
||||
|
|
||||
return node.type === 'FunctionDeclaration' || |
return node.type === 'FunctionDeclaration' || |
||||
( node.type === 'VariableDeclaration' && node.init && /FunctionExpression/.test( node.init.type ) ); |
( node.type === 'VariableDeclaration' && node.init && /FunctionExpression/.test( node.init.type ) ); |
||||
} |
} |
||||
|
Loading…
Reference in new issue