Run JavaScript (incl. jQuery, Ember.js and Handlebars) online with JS Bin


#1

While I was browsing a bit around, I did find a nice site called **JS Bin**:

JS Bin is a webapp specifically designed to help JavaScript and CSS
folk test snippets of code, within some context, and debug the code
collaboratively.

So you can register and create an own account with JS Bin. After that, you can upload code, run it and share it with others. One of the nice features is that you can add libraries like jQuery, Ember.js and Handlebars.

So if you are thinking about getting prepared for Stonehearth, this might be a nice way to play around with JavaScript and share some code.

P.S. And a possible starting point for Ember.js could be this one.


Notable Forum Posts by Likes
Notable Forum Posts
Learning how to mod Stonehearth
#2

jsFiddle is also a site to use for things like this


#3

I definitely recommend JSFiddle for this. :thumbsup:


#4

Or else there is the cloud9 IDE. It’s support a nice range of languages, there is even some lua support on the commandline. And since it’s an online cloudbased IDE, setup is really easy for beginners.


#5

I’ve used cloud9 IDE before and it is good. However, for stonehearth modding, the only thing it’s going to be able to do effectively is HTML, CSS, and Javascript. (In other words, UI stuff)

Even though it has command-line lua support, I don’t think it could run Stonehearth, which it would need to for you to fully test your mod.

Honestly, for HTML, CSS, and Javascript, you can use any text editor and your favorite browser on your local machine just fine. I recommend Sublime Text as a good text editor. It has an unlimited free trial. (Though you should pay the guy if you like it; it’s really great)


#6

I’m trying to figure out JS online, but I can’t get this code right, for some reason. I tried to simply call the function three times, like
creditCheck(75);
creditCheck(125);
creditCheck(100);

but that didn’t seem to work. Can anyone tell me what I’m doing wrong?


#7

Remove the comma after Alas. Codecademy is picky with those things :stuck_out_tongue:


#8

Yeah, as Warstories pointed out, the string that Codecademy was expecting isn’t the same string you gave them. Although yours may be more grammatically correct, programming is like that. For example, if you say if (“string” == “String”) {
…(random code)…

} This won’t do anything, as the S is capitalised in the second ‘String’.


#9

flfkldsjajf…

Stupid Codeacademy and your awful grammar…

I completely forgot that I had done that… Thanks.


#10

unless of course strtolower :stuck_out_tongue:


#11

His point was perfectly valid to show that case matters, using case changers is just a very useful technique in a lot of places. Also that function doesn’t exist in js, it’s str.toLowerCase


#12

Yeah, got it mixed up with php, same principle though