Samuel
@samuel.fm
this works in dev mode, but passing --no-dev means that the function never fires when you press the touchable. removing the void fixes it. wtf
2 10this is why i never touch javascript
1 7you might have a point
1 4JavaScript is not, in fact, a touchable, and trying to press it in production will fail, so you must send it to the void
1 6Probably IIFE? Never in my career have I needed to use a JS void keyword. "Welcome to JavaScript, where everything is made up and the rules don't matter" 🤣
1 3I think I had it there due to some dumb eslint rule, but it really shouldn’t change whether the function gets called or not!
2 3We definitely had the "no unhandled promises" eslint rule that suggested adding a void before the call that returned a promise to swallow it, but ran into similar issues like this.... `void` is evil in modern javascript, cast it away
2"shouldn't" 😅
Famous last words. "void 0" is short for "undefined" but void 1 probably isn't? (Or something equally as silly)