Fork me on GitHub
Samuel McHugh12:07:56

👋 Hello. Does shadow do some kind of caching on required npm modules per build? When I update some code in the node_modules (via npm link and a local project) I need to restart my build to see the changes.


yes, it does. you can touch package.json in the node_modules package to make it reload

🙌 1
Samuel McHugh12:07:28

thanks, will check it out

Samuel McHugh13:07:51

🤷 doesn;t seem to work for us. Maybe some added caveats because of the symlinking we're doing. Or some repl stickyness


Hi! I'm trying to load up apache-arrow 8.0.0 and shadow-cljs complains about the following:

Caused by:
IllegalStateException: Expected a property access: OBJECT_PATTERN 120:25  [length: 13] [source_file: node_modules/apache-arrow/io/adapters.js]
    STRING_KEY cmd 120:27  [length: 3] [source_file: node_modules/apache-arrow/io/adapters.js] [is_shorthand_property: 1]
        NAME cmd$jscomp$1 120:27  [length: 3] [source_file: node_modules/apache-arrow/io/adapters.js] [original_name: cmd]
    STRING_KEY size 120:32  [length: 4] [source_file: node_modules/apache-arrow/io/adapters.js] [is_shorthand_property: 1]
        NAME size$jscomp$23 120:32  [length: 4] [source_file: node_modules/apache-arrow/io/adapters.js] [original_name: size]
Is this a JS "target" issue e.g. es2015 vs esnext or something? I see there are multiple target packages published in but I'm unsure which one I'd want... I have my shadow-cljs build configured with :output-feature-set :es6 Thanks!


@hjrnunes that is an error from the closure compiler. can't say anything more about that either. maybe it is something it doesn't like. isn't this meant for node? are you trying to use it in a browser build?


whats the full error?


seems to be polyfill related, so :compiler-options {:output-feature-set :es-next} should maybe make it go away?


the code is using generator functions. could be a problem in how closure rewrites those


@thheller Yes, it's a browser build. I was under the impression this should support the browser too, but I'll double check. I'll update the compiler too, just in case. Thanks!


unfortunately if the language level doesn't fix it the only option is going with webpack instead as desribed here


making repros with only the closure compiler is kinda tough


OK, many thanks