Well here's a weird problem with fs.unlink for the JS experts:
User uploads file from mobile, it automatically gets uploaded using multer to a directory. Next the SQL database is updated with the link to that pic on the server. Finally, I take the previous link that was in the database and use fs.unlink to delete that old, useless file. Except it doesn't delete. Most of the times, a new file is created and the previous file is deleted after a 5-10 seconds. Why the delay?
If the state machine needs states, but the function that returns the states needs a reference to the state machine in order for those functions to change states...
@Mathan Welcome to the JavaScript chat! Please review the room pseudo-rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
Am trying to copy contents of PRE tag to clipboard, but i should not use flash/shockwave, i tried using zeroclipboard.js too but i was not able to achieve.. Can anyone help for the same?
@phenomnomnominal I tried the same logic which is there in clipboard.js file... Any other direct method is there to achieve... In that js hidden text area has been used...
Can you comunicate over processes in nodejs with phantomjs outside of stdout somehow? like you can do with different nodejs scripts: nodejs.org/api/…
...thinking there should be some kind of socket ...
...reading here: http://phantomjs.org/inter-process-communication.html I have now a bridge set up from nodejs to phantom, maybe better to comunicate over http protocol? Will look in to that I guess
Hi, I'm thinking about adding JavaScript logging to our app for developing purposes. I really love Chrome's console.group(), console.groupEnd(). Do you happen to know about a logging library that employs the functions? (Something like NLog for JS would be cool :-))
@Waterscroll Welcome to the JavaScript chat! Please review the room pseudo-rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
Hey gang. Anyone else noticed odd borders on items rendered in chrome this month? Like, you'll have something float left inside its parent and the parent's background shows up a little around the edges.
Are you experiencing the horrible hivemind of Stackoverflow too?
That if you link to w3schools - even if it's correct - it's still not the MDN bible
or if you try and put some character in your post by saying something which isn't robotic it gets replaced by someone else's answer who just copied the same content as yours without the 'good luck!' at the end.
Oh, and if you ask a question which you genuinely can't find online and the hivemind doesn't like it, you get -3 downvoted and lose your ability to comment on posts.
Just thought we were generally venting. Seems Waterscroll has gone.
Good grief, I've been fighting Vagrant for hours because npm install failed during provisioning and finally figured out it's because npm tries to use symlinks because it understands that it's running on ubuntu but the file system of the windows host does not support it so while I can clone and npm install using virtualbox it crashes with Vagrant :/
change the amp and sinecount and see what happens :D
converting degrees back into radians as you can see but you can change Math.PI inside the conversion formula to lets say 400 / 180 and see how the effect changes
In mathematics, a rose or rhodonea curve is a sinusoid plotted in polar coordinates.
== General overviewEdit ==
Up to similarity, these curves can all be expressed by a polar equation of the form
or, alternatively, as a pair of Cartesian parametric equations of the form
If k is an integer, the curve will be rose-shaped with
2k petals if k is even, and
k petals if k is odd.
When k is even, the entire graph of the rose will be traced out exactly once when the value of θ changes from 0 to 2π. When k is odd, this will happen on the interval between 0 and π. (More generally, this will happen on any...
oh I see, you're doing a loop with requestAnimationChange, well it could be in a simple for loop, but maybe your solution is better. Usually you use requestAnimationFrame for a more 'global' change
the idea of RAF is to draw at a given time, if you setTimeout you lose a bit this feature, what you could do is do a given number of empty RAF calls, between your actual ones
Can someone test a thing for me? I've some strange bug I noticed first on imgur, when I browse a page with a gif, the cpu starts working but never go down, after a minute on this page: i.sstatic.net/zyAXL.png I was over that gif for more than 60s, does it do that for you? I guess no