Skip to main content

How to install third party libraries?

Comments

3 comments

  • Stefan Schweigert

    Hi Zak,

     

    Take a look at this section in our documentation for info on including third-party libraries in custom activities: https://docs.geocortex.com/workflow/latest/help/Default.htm#wf5/help/custom-development.htm

     

    Thanks, Stefan

    0
  • Malcolm Walker
    • Community-Manager

    Thank you, @Stefan Schweigert? .

    After downloading the SDK folder, read readme.md file and it provides more useful information.

    0
  • Permanently deleted user

    Hi, could I get a some help please. I have followed the steps on Reference a Third Party Library for Web Application Environments but unable to get it working.

     

    First I have a simple javascript placed under dist/deps/rng/rng.js like below

    function rng() {

      return 100;

    }

    module.exports = rng;

     

    In the main.ts, I have

    import { mapDependencies } from '@geocortex/workflow/runtime/app/ActivityPackUtils';

    declare var require: Function;

    function configure(prefix: string) {

      mapDependencies({ myrng: '/deps/rng/rng' }, prefix);

    }

     

    in MyActivity.ts, I tried to import the third party library by

    import * as RNG from 'myrng';

     

    However, I got error says "Cannot find module 'myrng'."

     

    Any suggestions?

     

     

     

    0

Please sign in to leave a comment.