[Bug]: SyntaxError with file in node_module Unexpected token, expected "," (4:7), ...
See original GitHub issueMapbox Implementation
Mapbox
Mapbox Version
default
Platform
iOS
@rnmapbox/maps
version
10.0.0-beta.57 and older
Standalone component to reproduce
import React from 'react';
import {
MapView,
ShapeSource,
LineLayer,
Camera,
} from '@rnmapbox/maps';
const aLine = {
type: 'LineString',
coordinates: [
[-74.00597, 40.71427],
[-74.00697, 40.71527],
],
};
class BugReportExample extends React.Component {
render() {
return (
<MapView style={{flex: 1}}>
<Camera centerCoordinate={[-74.00597, 40.71427]} zoomLevel={14} />
<ShapeSource id="idStreetLayer" shape={aLine}>
<LineLayer id="idStreetLayer" />
</ShapeSource>
</MapView>
);
}
}
Observed behavior and steps to reproduce
No response
Expected behavior
No response
Notes / preliminary analysis
No response
Additional links and references
OS: Macbook pro M1 2021 React native: 0.68.2 NOTE: Our app still use JS code and function component. Please help here and feel free to request anything help reslove this issues.
Issue Analytics
- State:
- Created 10 months ago
- Reactions:3
- Comments:14 (6 by maintainers)
Top Results From Across the Web
SyntaxError with file in node_module Unexpected token ...
I have integration rnmapbox/maps#main via repo github in iOS and have some error from node_module. I have create issues in github too via...
Read more >Issues - GitHub
error : SyntaxError: .../node_modules/react-native/Libraries/Components/Touchable/Touchable.js: Unexpected token, expected "]" (25:45) #34719.
Read more >Why do i see the error SyntaxError: Unexpected token { on ...
Hi there! I've tried to deploy my website for some time now. This is the error, i really cant find any information about...
Read more >ts-node unexpected token 'export' - You.com | The Search ...
I'm getting SyntaxError: Unexpected token 'export' on some node_modules , which are not transpiled (I guess?). I worked around this by adding these...
Read more >JavaScript Error Handling: Unexpected Token - GeeksforGeeks
Unexpected token is similar to syntax error but more specific.Semicolon(;) in JavaScript plays a vital role while writing a programme. Usage: To ...
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 FreeTop 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
Top GitHub Comments
Hi @xotahal , Thanks for support me. I have downgrade to version
"@react-native-mapbox-gl/maps": "^8.5.0",
and it working now @@.Try to change it to
^7.x.x
. And make sure you getting all versions higher than 7.16. You can check this by runningyarn why @babel/core
. Many packages fetches the@babel/core
. Also runyarn dedupe
to get rid of versions you don’t need. Hope it helps 😉