Haul: Debug JS remotely with typecript

Created on 9 Aug 2017  路  5Comments  路  Source: callstack/haul

Current Behavior

Remote JS debugging does not work with typescript and haul version 1.0.0-beta.4. When you try and debug js remotely the following error is thrown: Cannot read property 'BlobBuilder' of undefined

Expected Behavior

Currently downgrading to version 1.0.0-beta.2 of haul allows the JS to be remotely debugged version 1.0.0-beta.4 of haul should behave the same.

Haul Configuration (webpack.haul.js)

I am using the typescript configuration that allows synthetic imports which can be found here: https://github.com/callstack-io/haul/blob/master/docs/Recipes.md#typescript

Your Environment

| software | version
| ---------------- | -------
| Haul | 1.0.0-beta.4
| react-native | 0.47.1
| node | 8.1.4
| yarn | 0.27.5

Most helpful comment

In my case this was caused by the socket.io-client dependency bundled with Reactotron. Removing Reactotron fixed the issue.

All 5 comments

In my case this was caused by the socket.io-client dependency bundled with Reactotron. Removing Reactotron fixed the issue.

I'm getting this error (Cannot read property 'BlobBuilder' of undefined) when trying to launch the remote debugger while using haul and reactotron in conjunction. Granted, reactotron still works fine so in most cases I don't _need_ the remote debugger, but it's still quite strange

I think it has something to do with the way i load socket.io.

Loading it with var io = require('socket.io-client') might be a fix.

I guess the execution environment of javascript is different while chrome debugging, so I think BlobBuilder needs to be handled differently. This may be what loading socket.io-client directly does.

What I type into my editor and what runs is pretty far apart these days. 馃樃

In v2 we ended up removing socket.io entirely from Reactotron. A little websocket-ery does the trick just fine.

If you do pin it down, lemme know tho (either here or over on our repo).

@skellock I'll be looking forward to v2 then! We actually just today updated to v1.13.2 and remote debugging seems to be working again 馃帀

Is this closable? Our project uses Typescript and we've had debugging working on the last several versions.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Traviskn picture Traviskn  路  4Comments

hesyifei picture hesyifei  路  4Comments

jounii picture jounii  路  5Comments

satya164 picture satya164  路  5Comments

dave-irvine picture dave-irvine  路  4Comments