Skip to content

Commit

Permalink
  fix: trying to fix cors on flow
Browse files Browse the repository at this point in the history
  • Loading branch information
dlohvinov committed Mar 25, 2024
1 parent 104bc7e commit 25558bc
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ export default {
async initDiagram() {
const flowDiagramUrl = import.meta.env.VITE_FLOW_DIAGRAM_URL;
const script = document.createElement('script');
script.src = `${flowDiagramUrl}/WtFlowDiagram.umd.min.js`;
// script.type = 'module';
script.src = `${flowDiagramUrl}/WtFlowDiagram.umd.cjs`;
script.onload = () => {
const params = {
// if edit, restore diagram
Expand Down Expand Up @@ -82,7 +84,7 @@ export default {
},
},
};
const WtFlowDiagram = window.WtFlowDiagram.default;
const WtFlowDiagram = window.WtFlowDiagram;
this.diagram = new WtFlowDiagram('#flow-diagram', params);
const onSave = async ({
Expand Down

0 comments on commit 25558bc

Please sign in to comment.