Fork me on GitHub
#clojurescript
<
2018-10-22
>
tslocke08:10:32

Any tips for debugging a problem with :npm-deps? I'm trying to import react-flip-toolkit. Compiles fine but as soon as I add [react-flip-toolkit] to one of my namespace requires I start getting Undefined nameToPath for module$...project...$node_modules$react_flip_toolkit$es$flip. I have other npm-deps working fine (e.g. react-dnd).

alcamech17:10:14

Im using reagent and semantic ui for a web app. I am change the css class based on a particular condition. However, once I go to another page and come back the css changes are gone. How can I cache them ?

alcamech17:10:26

changing the css class*

dnolen17:10:42

why you need to cache them?

dnolen17:10:57

they should be derived from props or state and you won’t have this problem

borkdude21:10:06

bug or feature? (assoc nil 'lol 'lol 'lol)

mfikes21:10:24

Undefined behavior IMHO

andy.fingerhut21:10:30

Clojure/Java's assoc throws exception due to wrong number of args

mfikes21:10:02

Right, it throws IllegalArgumentException which means "your program is incorrect"

mfikes21:10:50

Yeah, your program is incorrect, so a dancing frog can jump out of the box, and that would fall within the scope of undefined behavior πŸ™‚

andy.fingerhut21:10:33

Thankfully most of Clojure and ClojureScript's actual undefined behavior is significantly less surprising than that πŸ™‚

mfikes21:10:01

Just once, I would like to see my program do this, and my life will be complete. For those who are curious: https://www.youtube.com/watch?v=MsROL4Kf8QY

andy.fingerhut21:10:58

Hmmm, using ClojureScript's equivalent of Clojure/Java's clojure.java.browse/browse-url, and that URL, that is a pretty small patch πŸ™‚

πŸ‘Œ 4