`?.` Module parse failed: Unexpected token
See original GitHub issueChecks
- Not a duplicate.
- Not a question, feature request, or anything other than a bug report directly related to React Splide. Use Discussions for these topics: https://github.com/Splidejs/splide/discussions
Version
0.6.5
Description
I only know the ?.
syntax from TypeScript and I think that’s the issue here.
ERROR in /node_modules/@splidejs/react-splide/dist/js/react-splide.esm.js 2449:16
Module parse failed: Unexpected token (2449:16)
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
| }
| go(control) {
> this.splide?.go(control);
| }
| getSlides() {
Reproduction Link
No response
Steps to Reproduce
- Install current react-splide version
- Try to build it with webpack using es modules
Expected Behaviour
Should build without error
Issue Analytics
- State:
- Created 2 years ago
- Comments:16
Top Results From Across the Web
Module parse failed: Unexpected token - Stack Overflow
Apparently it happened because you have two module properties in the webpack config object. Given JS objects can only hold one value per...
Read more >Module parse failed: Unexpected token. You may ... - GitHub
This is a library build issue. We moved to ts3.8 without thinking about optional chaining transpiling. Here seems like a correct way to...
Read more >Odyssey Lift-off I: "Module parse failed: Unexpected token" Error
Hello, I am on the “useQuery hook” step attempting to implement the grid. Here is my code that I think is problematic: const...
Read more >module parse failed: unexpected token (1:0) you may need an ...
Module parse failed: Unexpected token - Stack Overflow ... 1 Answer. Apparently it happened because you have two module properties in the webpack...
Read more >Module parse failed: Unexpected token (1:0) - Laracasts
Hello , After running npm run watch I see this error : ERROR in ./resources/js/components/irp/admin/EditGroup.vue 1:0 Module parse failed: Unexpected token ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I transpiled the chaining syntax(^0.6.7).
Could someone help me to get the exact issue here.