wso2/identity-apps

Build failing due to typings issue.

brionmario opened this issue · 0 comments

Describe the Issue:
When running a clean installed build, the build fails.

How To Reproduce:

  1. Clean all the lock files by executing npm run clean-all
  2. Execute npm run build.
  3. Check the console.
@wso2is/core: src/helpers/documentation.ts(36,56): error TS2339: Property 'nav' does not exist on type 'string | object'

Possible reasons:
Type declarations of the library has been updated and the return type of safeLoad() function has been changed [1].

Before

export function safeLoad(str: string, opts?: LoadOptions): any;

After

export function safeLoad(str: string, opts?: LoadOptions): string | object | undefined;

Temporary fix:
Remove the ^ mark to prevent installing the version with the above changes.

[1] DefinitelyTyped/DefinitelyTyped@14f1fea