Quantcast
Channel: XWiki Forum - Latest topics
Viewing all articles
Browse latest Browse all 1220

Coding style: use re-exports instead of import+export

$
0
0

Related to [Misc] Use re-export statements instead of import -> export by ClementEXWiki · Pull Request #683 · xwiki-contrib/cristal · GitHub

Currently in Cristal, re-exports in TypeScript are done this way:

import { obj } from 'module';
export { obj };

I think it would be better to use the following syntax, which is built into TypeScript:

export { obj } from 'module';

It makes the code both more readable and more maintainable, avoiding duplicates.

What do you think?

2 posts - 2 participants

Read full topic


Viewing all articles
Browse latest Browse all 1220

Trending Articles