0

I am integrating @jack-henry/banno-plugin-framework-bridge module in the plugin server. I have installed it globally and copied the banno-plugin-framework-bridge.js from dist folder to the root folder of the plugin server. I then included it in the response HTML as per following

<script type="module">
    import { enableRouter } from "./banno-plugin-framework-bridge.js";
    enableRouter();
</script>

Is this procedure right? Also, I get the following error: Cannot GET /banno-plugin-framework-bridge.js. What must be going wrong?

Ravindra
  • 93
  • 1
  • 10
  • It depends a lot on the specific tech stack that you are using. We have installation steps for _Node.js_, in particular. You'll have to adapt those steps to what works for your platform in terms of adding JavaScript modules. https://jackhenry.dev/open-api-docs/plugins/architecture/userinterface/banno-plugin-framework-bridge/#installation – Jaime Lopez Jr. Apr 29 '22 at 19:27
  • I am using Node.js stack and following the documented steps. – Ravindra Apr 30 '22 at 01:23
  • I'm somewhat confused because the original question mentions "[...]copied the banno-plugin-framework-bridge.js from dist folder to the root folder of the plugin server.". When installing via a `package.json` dependency (and using `npm install`), I would expect the module to be loaded into `node_modules` and not require manual copying to a separate location. – Jaime Lopez Jr. May 02 '22 at 23:26
  • Likewise, the location is slightly different in the docs with a `/js` at the beginning of the location rather than a `./` at the beginning i.e. `import { enableRouter } from "/js/banno-plugin-framework-bridge.js";`. – Jaime Lopez Jr. May 02 '22 at 23:27
  • You are right in the above two comments. But I deviated because when I used this line `import { enableRouter } from "/js/banno-plugin-framework-bridge.js";`, in the response, I got the 404 error. `display1:4 GET https:///js/banno-plugin-framework-bridge.js net::ERR_ABORTED 404 (Not Found)` This was my original problem. I should have stated this at the outset, in the problem description. So I experimented with static file serving through the root folder. And the result is part of the problem description. – Ravindra May 04 '22 at 08:43
  • It's unclear if you are running a project on your local machine or if this is deployed on a server. Can you provide some insight? – Jaime Lopez Jr. May 05 '22 at 16:33
  • It is deployed on a server – Ravindra May 06 '22 at 17:10
  • Interesting. To help narrow down the possibilities, what happens if you run the code locally? – Jaime Lopez Jr. May 09 '22 at 15:16
  • Not sure if this helps, but the "Enabling" and "Installation" sections have been updated in https://jackhenry.dev/open-api-docs/plugins/architecture/userinterface/banno-plugin-framework-bridge/. Hopefully this reduces some confusion on how you can serve up the Plugin Bridge files. – Jaime Lopez Jr. Nov 10 '22 at 19:11

0 Answers0