by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Mar 02 04:10
    jchud13 closed #106
  • Mar 02 04:10
    jchud13 commented #106
  • Mar 02 04:02
    whacked commented #106
  • Mar 02 03:15
    jchud13 opened #106
  • Sep 05 2019 11:30
  • Sep 05 2019 11:29
    madelinekosse synchronize #105
  • Sep 05 2019 11:12
  • Sep 05 2019 11:11
    thisdotrob synchronize #105
  • Apr 23 2019 09:57
  • Apr 23 2019 09:56
    thisdotrob synchronize #105
  • Apr 18 2019 09:09
  • Apr 18 2019 09:08
    thisdotrob synchronize #105
  • Apr 17 2019 14:08
  • Apr 17 2019 14:06
    thisdotrob synchronize #105
  • Apr 03 2019 11:00
  • Apr 03 2019 10:59
    thisdotrob edited #105
  • Apr 03 2019 10:59
    thisdotrob opened #105
  • Dec 02 2018 01:02
    francescoagati commented #104
  • Dec 02 2018 01:02
    francescoagati closed #104
  • Nov 30 2018 23:19
    francescoagati commented #104
francesco agati
@francescoagati
the files and macro are cached
@sleepyfox
@sleepyfox
Hi @francescoagati - not as far as I'm aware - although it's supposed to be possible to delete from the require cache I can't actually get it to work in node:current :-(
francesco agati
@francescoagati
@sleepyfox thanks
Alexander Vega
@Unimplied
Hey everyone, I was wondering if sibilant had comparison operators? I'm trying to compare to values in two separate lists, but keep getting an unexpected token exception.
Jacob Rothstein
@jbr
Sibilant does have comparison operators like <, <=, > & >=. They’re prefix not infix, like (< a b)
Jared Chudzinski
@jchud13
Hello everyone! I need a bit of help,
How can I do something like var count = seen[input]; in sibilant?
Jared Chudzinski
@jchud13
Found help on github forums thank you for your time
Cesar Marinho
@cesarmarinhorj
thanks for this amazing piece of software! great job!
whats the best way to embed js functions inside a sibilant (lisp) file?
Jacob Rothstein
@jbr
@cesarmarinhorj Thanks! As far as embedding, do you mean using them from within sibilant or directly compiling them into the file?
those would be slightly different. In general, it’s probably preferable to keep the language boundaries between files, using the require system
so if you have some js you want to use from within sibilant, save it as a .js file and require it
Cesar Marinho
@cesarmarinhorj
thanks!!! gonna try!!!
Cesar Marinho
@cesarmarinhorj
how can include/require another sibilant (lisp) scripts?
Jacob Rothstein
@jbr
or just require
Cesar Marinho
@cesarmarinhorj
works! thanks
Cesar Marinho
@cesarmarinhorj
which data structures will be supported?
Jacob Rothstein
@jbr
"it’s just javascript.”
anything you use in javascript. sibilant was/is a tool for writing javascript, and doesn’t impose any constraints on that. it hasn’t been updated for modern js, but that doesn’t limit the use of any particular data structures
Despagito
@despagito
@jbr Does that mean I can use all javascript APIs?
Anybody know how to append element to an array now that "append" is deprecated?
Jacob Rothstein
@jbr
@despagito exactly, yes. Any js that works in the compiled file works in sibilant
To append, you can use any of the array prototype methods you’d use in normal js, like push and pop and shift and unshift
Or ... if you’re looking to expand an array into an array literal
Despagito
@despagito
Thanks @jbr But when I use those normal methods, I got error "push is not defined"
Do I need to add any configuration to use them?
Jacob Rothstein
@jbr
(Like in js, [1 2 3 ...[3 4 5]] is 1 through 5 in one array)
Well, with two 3s because I’m an idiot
I’d need to see how you’re calling push. There’s no confirmation needed
Do you have an array in a variable and want to add something new to it, or are you constructing a literal array and want to expand another array into it?
Despagito
@despagito
  (each-key task pre
    (if (= 0 (get pre task))
      (push starts task)
    )
  )
  (var starts [])
  (each-key task pre
    (if (= 0 (get pre task))
      (push starts task)
    )
  )
I have an empty array - starts
Jacob Rothstein
@jbr
Either (.push starts task) or (starts.push task)
Despagito
@despagito
That dot is amazing!
.push works!
Thank you so much @jbr
Jacob Rothstein
@jbr
✨ you’re welcome! enjoy!
Jackie S
@eikkaj
Howdy, I have an array of objects and would like to simply loop thru and check if the array in the object that is in the array is empty. an example of what my array of objects may look like: ;;[{a 'helloa', b ["hellob"]}] . I'm getting an error TypeError: (intermediate value).call(...) is not a function and was hoping for some advice
(def myfunc (objs)
  (each obj objs (
      (if 
          (empty? obj.b)
              (do
                  (console.log "b is empty"))
          )
      )
  )
 )
Aaron Beavers
@riatzukiza
You have too many parenthesis around your if expression. Your getting that error because your trying to call the if expression.
@eikkaj
Jacob Rothstein
@jbr
(def myfunc (objs)
  (each obj objs 
    (when (empty? obj.b)
       (console.log "b is empty"))))
Jackie S
@eikkaj
thanks! sorry for the dumb q
Jacob Rothstein
@jbr
no worries, no dumb questions! thanks for learning sibilant!
Mathäus
@m3tti
hey guys who is using sibilant in production
and how is it??
i just found out about it