Clojurians
#cljsjs
<
2016-01-22
>

This page is not created by, affiliated with, or supported by Slack Technologies, Inc.

thomas15:01:32

When I have this bit of JavaScript:

thomas15:01:41

`message = new Paho.MQTT.Message("Hello"); message.destinationName = "/World";`

thomas15:01:10

how do I define the destinationName in my extern? at the moment end up with destinationName undefined when I run my code...

thomas15:01:48

which implies that it got optimised away by the google clojure compile. but not sure how I do this in the extern file.

thomas15:01:06

any help greatly appreciated!

juhoteperi15:01:09

@thomas: I think you can just define the property in extern file like the methods, but instead of using function () {}, define the value as empty string or something

thomas15:01:57

ok, I will try that. Thank you.

yenda16:01:33

I am trying to use bootstrap with cljsjs but I feel like there is some missing steps in the readme

yenda16:01:41

ok the css is not included I had to add it

futuro17:01:39

Hey all, if I include a cljsjs package, do I still need to include the js lib with a <script> tag in my html? Or does cljsjs import the js package for me?

juhoteperi17:01:07

@futuro: ClojureScript compiler will include the source in Cljs output JS

futuro17:01:30

@juhoteperi: Oh, that's really handy. Thank you simple_smile

snoe23:01:28

Hi @juhoteperi I mentioned nodejs and optimizations the other day, and I did some more digging and one part of the missing piece for package maintainers is being able to specify :module-type :commonjs inside the foreign-libs map. Basically this: http://mneise.github.io/posts/2015-07-08-week-6.html I'm not sure how that affects browsers but I thought you'd like to know.