ds300 / react-native-typescript-transformer

Seamlessly use TypeScript with React Native
MIT License
657 stars 50 forks source link

rn 0.52.0 TypeError: Cannot read property 'sections' of undefined #38

Closed dluksza closed 6 years ago

dluksza commented 6 years ago

After migrating to react-native 0.52.0 and updating react-native-typescript-transformer to current master (commit: 5c428f8eeaa10) I'm getting following error

error: bundling failed: TypeError: Cannot read property 'sections' of undefined
    at new SourceMapConsumer (node_modules/source-map/lib/source-map-consumer.js:20:20)
    at composeSourceMaps (node_modules/react-native-typescript-transformer/index.js:89:25)
    at Object.module.exports.transform (node_modules/react-native-typescript-transformer/index.js:192:9)
    at Object.transformCode [as transform] (node_modules/metro/src/JSTransformer/worker/index.js:207:15)
    at execMethod (node_modules/metro/node_modules/jest-worker/build/child.js:92:29)
    at process.on (node_modules/metro/node_modules/jest-worker/build/child.js:42:7)
    at emitTwo (events.js:126:13)
    at process.emit (events.js:214:7)
    at emit (internal/child_process.js:772:12)
dluksza commented 6 years ago

This is a known issue: https://github.com/ds300/react-native-typescript-transformer/pull/37#issuecomment-355996942

ds300 commented 6 years ago

Thanks for the report. I just published a fix for this in 1.1.6

dluksza commented 6 years ago

Verified that this error doesn't occur on 1.1.6