Code Monkey home page Code Monkey logo

Comments (12)

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024 2

finnally, i figure it out , cause preact duplicate, see https://github.com/Ken-Scofield/bpmn-form-demo,

resolve: {
      alias: {
        preact: path.resolve(__dirname, 'node_modules/preact'),
        '@bpmn-io/properties-panel/preact': path.resolve(__dirname, 'node_modules/preact'),
        '../preact': path.resolve(__dirname, 'node_modules/preact')
      }
},

3 path are used to import preact , set 3 alias to resolve it, I don't know if it's correct, but it does solve the problem.

from form-js-examples.

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024 1

@Skaiir

from form-js-examples.

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024

it's seems somewhere read hooks.module.js in error place, i cant figure it out? help!

from form-js-examples.

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024

And, if i add this webpack config, I got another error in bpmnjs : EventBus.js:421 unhandled error in event listener TypeError: Cannot read properties of null (reading '__H') , help help help... bpmnjs report.

from form-js-examples.

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024

@nikku can you help me? Is this because of the dependency "preact" ?

from form-js-examples.

nikku avatar nikku commented on August 13, 2024

Ensure you de-duplicate preact. Which example can you reproduce this with?

from form-js-examples.

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024

Ensure you de-duplicate preact. Which example can you reproduce this with?

https://github.com/Ken-Scofield/bpmn-form-demo.git,my demo address, please carry me.

from form-js-examples.

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024

Running with webpack5. Can't use "playground" and something else at the same time, OR, how to de-duplicate preact in webpack5?

from form-js-examples.

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024

And i try :
resolve: {
alias: {
preact: path.resolve(__dirname, 'node_modules/preact'),
'../preact': path.resolve(__dirname, 'node_modules/preact')
// 'preact/hooks': path.resolve(__dirname, 'node_modules/preact/hooks/dist/hooks.module.js'),
// 'preact/jsx-runtime': path.resolve(__dirname, 'node_modules/preact/jsx-runtime/dist/jsxRuntime.module.js'),
// 'preact/compat': path.resolve(__dirname, 'node_modules/preact/compat/dist/compat.module.js')
}
},
then bpmnjs not worked?
999

from form-js-examples.

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024

I have used form-js-example and bpmn-js example in one project, and they cant work in the same time cause of preact module . Please help me firgure it out, Thanks ! @nikku

from form-js-examples.

nikku avatar nikku commented on August 13, 2024

@Ken-Scofield Beyond aliasing (which always works) npm dedupe or explicit dependency versioning through
overrides are known to work techniques to address this issue.

from form-js-examples.

Ken-Scofield avatar Ken-Scofield commented on August 13, 2024

@Ken-Scofield Beyond aliasing (which always works) npm dedupe or explicit dependency versioning through overrides are known to work techniques to address this issue.

Thank you very much, I've learned

from form-js-examples.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.