Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
}
// export { n as b, m as c };
if (i.type === AST_NODE_TYPES.ExportNamedDeclaration && i.specifiers) {
return false;
}
// export default class Foo {};
// @ts-ignore (remove after https://github.com/typescript-eslint/typescript-eslint/pull/378 is merged)
if (i.type === AST_NODE_TYPES.ExportDefaultDeclaration) {
throw new Error('ExportAllDeclaration is not supported in Storybook config');
/* This is not supported because we don't have a config property called 'default' */
}
// export * from 'foo';
if (i.type === AST_NODE_TYPES.ExportAllDeclaration) {
throw new Error('ExportDefaultDeclaration is not supported in Storybook config');
/* This is not supported because we'd have to recurse into the modules which would add a lot of complexity */
/* The solution is the make exports explicit */
}
return true;
}, []);
str += this.codeFromDebuggerStatement(ast);
break;
case AST_NODE_TYPES.Decorator:
str += this.codeFromDecorator(ast);
break;
case AST_NODE_TYPES.DoWhileStatement:
str += this.codeFromDoWhileStatement(ast);
break;
case AST_NODE_TYPES.EmptyStatement:
str += this.codeFromEmptyStatement(ast);
break;
case AST_NODE_TYPES.ExportAllDeclaration:
str += this.codeFromExportAllDeclaration(ast);
break;
case AST_NODE_TYPES.ExportDefaultDeclaration:
str += this.codeFromExportDefaultDeclaration(ast);
break;
case AST_NODE_TYPES.ExportNamedDeclaration:
str += this.codeFromExportNamedDeclaration(ast);
break;
case AST_NODE_TYPES.ExportSpecifier:
str += this.codeFromExportSpecifier(ast);
break;
case AST_NODE_TYPES.ExpressionStatement: