HTML5 development in 9.1 : Adding custom imx-api-ccc.tgz breaks compilation

Hi,

In v91, according to the documentation and the github project, I've setup a working environment for html5 dev , everything works fine. Node version is 14, all modules are built flawlessly. 

I've added a custom app that builds ok too. Now I've created a custom api with a custom imx-api-ccc.tgz generated by imxclient, placed in the correct folder and added to my custom-app. Nothing wrong so far. The custom api works fine, tested and working with the swagger ui (we're really happy with this, it's been a long way)

My custom app needs qbm among others. Now , whenever I try to compile the qbm (ng build qbm) library I get the following error:

"Heavy multiplication x Compiling with Angular sources in Ivy partial compilation mode.
projects/qbm/src/lib/chart-options/line-chart-options.ts:27:24 - error TS2614: Module '"billboard.js"' has no exported member 'LineOptions'. Did you mean to use 'import LineOptions from "billboard.js"' instead?"

I've created and recreated the same scenario to end up with the same error.  Same happens if I try to compile qer or the custom-app.

Apologies for my lack of angular knowledge.

Any hints?

Parents
  • The error you're encountering is due to how LineOptions is exported from billboard.js. In newer versions, LineOptions is likely the default export, not a named export. So instead of:

    import { LineOptions } from 'billboard.js';
    

    You should use:

    import LineOptions from 'billboard.js';
    

    This change aligns with the TypeScript error message. Verify the billboard.js version in your project and its export style. You may also consider downgrading or locking the version to one that supports named exports, if that fits your compatibility needs.

Reply
  • The error you're encountering is due to how LineOptions is exported from billboard.js. In newer versions, LineOptions is likely the default export, not a named export. So instead of:

    import { LineOptions } from 'billboard.js';
    

    You should use:

    import LineOptions from 'billboard.js';
    

    This change aligns with the TypeScript error message. Verify the billboard.js version in your project and its export style. You may also consider downgrading or locking the version to one that supports named exports, if that fits your compatibility needs.

Children
No Data