Uniformize folder structure (#693)
* Uniformize folder structure * Fix icons * Fix icons * Fix tests * Fix tests
This commit is contained in:
15
front/src/utils/isNonEmptyString.ts
Normal file
15
front/src/utils/isNonEmptyString.ts
Normal file
@ -0,0 +1,15 @@
|
||||
import { isDefined } from './isDefined';
|
||||
|
||||
export function isNonEmptyString(
|
||||
probableNonEmptyString: string | undefined | null,
|
||||
): probableNonEmptyString is string {
|
||||
if (
|
||||
isDefined(probableNonEmptyString) &&
|
||||
typeof probableNonEmptyString === 'string' &&
|
||||
probableNonEmptyString !== ''
|
||||
) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
Reference in New Issue
Block a user