GithubHelp home page GithubHelp logo

Comments (11)

acywatson avatar acywatson commented on April 27, 2024

I suspect this is your problem: https://stackoverflow.com/questions/51860043/javascript-es6-typeerror-class-constructor-client-cannot-be-invoked-without-ne

Have you tried targeting a later version of javascript in your transpilation? Or is there a reason why you need to target es6?

from lexical.

The-Code-Monkey avatar The-Code-Monkey commented on April 27, 2024

My tsconfig is targeting esnext not es6

from lexical.

The-Code-Monkey avatar The-Code-Monkey commented on April 27, 2024

Also it builds fine it's just when I use it in another package

from lexical.

acywatson avatar acywatson commented on April 27, 2024

My tsconfig is targeting esnext not es6

Ah, I see - I missed the base config you extended.

Also it builds fine it's just when I use it in another package

I'd expect the transpilation to work fine, anyway. You'd see a runtime error (which is what you're seeing, right?).

Do you think you could provide a stack trace? I can't repro this in the playground with the same setup (another thing pointing to an environment/build issue).

from lexical.

The-Code-Monkey avatar The-Code-Monkey commented on April 27, 2024

@acywatson I've posted a minimal reproduction using code sandbox issue happens there for me, anything that is currently on the GitHub link I sent is that package version that's in the code sandbox

from lexical.

The-Code-Monkey avatar The-Code-Monkey commented on April 27, 2024

Another thing to note I have tested it locally using storybook and all is fine. All I can guess is that my rollup build command is breaking something but I wouldn't have thought so.

from lexical.

acywatson avatar acywatson commented on April 27, 2024

Hmm - one quick test could be to search the built files for "TextNode.call" and see if that's happening anywhere.

from lexical.

The-Code-Monkey avatar The-Code-Monkey commented on April 27, 2024

Hmm ok I'll try that tomorrow. It would be nice to see a working example of this sort of feature as even their own playground doesn't show this off

from lexical.

The-Code-Monkey avatar The-Code-Monkey commented on April 27, 2024

@acywatson there is a textnode.call in the cjs built file but only within the extendedTextNode constructor where you would expect it to be.

I cannot find the same thing in the esm version.

from lexical.

Related Issues (20)

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.