KevinVandy / material-react-table

A fully featured Material UI V5 implementation of TanStack React Table V8, written from the ground up in TypeScript
https://material-react-table.com
MIT License
1.46k stars 418 forks source link

react expo giving @tanstack/virtual-core/build/lib/index.esm.js 124:92 You may need an appropriate loader to handle this file type #318

Closed mxmujeeb2 closed 1 year ago

mxmujeeb2 commented 1 year ago

material-react-table version

v1.5.7

react & react-dom versions

"react": "18.1.0", "react-dom": "18.1.0"

Describe the bug and the steps to reproduce it

i build react native expo basic project and added material-react-table v1.5.7 . Then added the basic example given but it gave below error : ./node_modules/@tanstack/virtual-core/build/lib/index.esm.js 124:92 Module parse failed: Unexpected token (124:92) You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders | sync | } = _ref;

const toOffset = (sync ? offset : offset + instance.options.scrollMargin) + (adjustments ?? 0); | (_instance$scrollEleme = instance.scrollElement) == null ? void 0 : _instance$scrollEleme.scrollTo == null ? void 0 : _instance$scrollEleme.scrollTo({ | [instance.options.horizontal ? 'left' : 'top']: toOffset,

Minimal, Reproducible Example - (Optional, but Recommended)

I have written in above description

Screenshots or Videos (Optional)

No response

Do you intend to try to help solve this bug with your own PR?

None

Terms

KevinVandy commented 1 year ago

I don't think it is possible for this library, or even Material UI to work in React Native. If it is possible, I'd be surprised, as it is not something this library is trying to support. Probably same with virtual as it relies a lot on the dom stuff.

KevinVandy commented 1 year ago

Closing this as Material UI and MRT do not and are not meant to work in React Native.