Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
e5e3a78 to
8362ad6
Compare
|
Edit:
|
fe2bbac to
cc37aba
Compare
packages/lexical-playground/src/nodes/ExcalidrawNode/ExcalidrawModal.tsx
Outdated
Show resolved
Hide resolved
29af025 to
0f59ce4
Compare
|
Now, there aren't any tsc errors with either |
b0a6902 to
983a50b
Compare
cd53d07 to
2e67d5f
Compare
2e67d5f to
e373bc8
Compare
e373bc8 to
9071b9d
Compare
|
rebased and resolved new errors. I guess It's ready unless failing
|
| "react-dom": "^18.2.0", | ||
| "react-error-boundary": "^3.1.4", | ||
| "y-websocket": ">=1.3.x", | ||
| "y-websocket": "^1.5.4", |
There was a problem hiding this comment.
with bundler, importing y-websocket throws an error

y-websocket maintainer’s comment for fixing this: update to ^1.5.0
yjs/y-websocket#133 (comment)
|
What do you expect this to break (if anything) and what’s the upgrade path? |
With // jest.config.js
'^@lexical/react/src/(.*)$': '<rootDir>/packages/lexical-react/src/$1',this fails to resolve the paths somehow, leading unit tests to fail. And also just aligning the path with the way we do in tsconfig path alias seems more easy to maintain. Different imports for same path were easily allowed. There are some more in unit test codes. // i.e. both are used in unit tests
import {useLexicalComposerContext} from '@lexical/react/LexicalComposerContext';
import {useLexicalComposerContext} from '@lexical/react/src/LexicalComposerContext';So I updated path matchers in jest config for unifying imports in unit tests and make it work with
I think it's fine with both or In certain apps using lexical with |
|
Close this since it is incorporating to #5774 . |
fixes #5710
fixes #5117
fixes #4160
This will support correct type inference with
moduleResolution: bundleroption of tsconfig, which is default on creat next app, create vite.Currently, when importing
lexcialor@lexical/...withmoduleResolution: bundler,.d.tsfiles resolves'.'to the main entry on package.json.So if some types are imported with
'.', this ends up being inferred asany.For example, ElementNode here is imported from
'.'.This should have inferred like this. LexicalNode is not imported from
'.'so it works:With adding entry for types, it can infer correct type with
moduleResolution: bundler.