JavaScript is the original and common name applied towards most flavors of a scripting language that originated on NetScape Navigator. Use this tag for questions regarding common implementations of ECMAScript, JavaScript, JScript, etc. JS does not typically refer to its ECMA-cousin, ActionScript.

learn more… | top users | synonyms

1
vote
1answer
110 views

Should I not try to emulate private class data in javascript?

So I have been building this ORM style library for AngularJS (JavaScript) and since I come from a C++/PHP/C# background, I always try to make sure that private things stay private. While this can be ...
0
votes
0answers
28 views

Masking effect using HTML5 canvas [migrated]

I'm just a junior developer and I am wrestling with a bug and not sure how to fix. If you see this example: http://jsfiddle.net/gfZ5C/ When user mouseout from the image, a large circle is left at ...
0
votes
0answers
58 views

Refactoring this javascript code [closed]

I have this javascript code and im not happy the way it is written.. function notesViewModel() { _this.colName = "CreatedDate"; _this.sortOrder = "desc"; _this.notes = ...
0
votes
2answers
106 views

Repetitive Drawing in Javascript & Canvas

Creating an HTML5 page using canvas and javascript to draw a set number of musical staves on the page, spaced a pre-determined amount in between. What I have is re-drawn on top of the canvas 10 ...
-1
votes
0answers
64 views

Why are people using CoffeeScript instead of LiveScript? [closed]

If you read the whole thing on http://livescript.net/ , you'll probably agree with me it's just CoffeeScript done right. It doesn't only solve all of CoffeeScript weird problems but it's syntax is ...
0
votes
0answers
41 views

data handling with javascript

Python has a very neat package called pandas which allows for quick data transformation; tables, aggregation, that sort of thing. A lot of these types of functionality can also be found in the python ...
1
vote
2answers
67 views

Making a flowchart showing step by step processes with HTML5 or Javascript or CSS3? [closed]

I want to make the flowchart like in this image I have: I am guessing I can achieve it by using HTML5 Canvas but I am complete beginner when it comes to HTML5 & I have some time constraints. ...
-1
votes
0answers
49 views

Can you give me any book recommendations for knockout and backbone JavaScript libraries? [closed]

Can anyone recommend a great intro book for knockout.js and also backbone.js? And then also an advanced book for both? Thanks! If this isn't the place to ask this, please point me in the right ...
0
votes
2answers
165 views

Multi-Threaded JavaScript?

I know, I know--it isn't possible presently BUT my question is this: Would it be possible to write a browser plug in for the major browsers that enables true, multi-threaded JavaScript? It just ...
-1
votes
2answers
413 views

What are some interview questions I can expect for a technical evaluation? [closed]

I am 20 years old and I've been doing some web development work for about 2 years or so. I have an interview for a Junior Web Developer position and the company knows that but I'll still be going ...
2
votes
2answers
129 views

JavaScript Frameworks for traditionally structured web applications

I am looking for a way to control large amounts of JavaScript code in a ASP.Net MVC web application. I have been looking at Ember.js and whilst it's pretty compelling it takes control of the routing ...
1
vote
1answer
105 views

Documenting Function That Takes Random Parameters?

What's the best approach to creating documentation (displaying the function prototype if you will) for functions that take a variety of different forms in terms of parameters. Let's say there are 10 ...
0
votes
1answer
100 views

Converting a user management system to use ajax

I am currently building a website, which until quite recently was purely PHP. However I am now making trying to have the site use more AJAX, to lessen the page reloads. In PHP I had a lovely object ...
0
votes
0answers
26 views

What tools can I use to create static demonstration documentation?

As we embark on a project of javascript UI widgets, we need to create demonstration documentation on these widgets. However, we can't create said documentation using a CMS. These should be static ...
-3
votes
0answers
65 views

How to identify code or solve issue which makes browser (chrome) crash

Is there any standard practices to solve/debug issues which makes browser crash? I have been debugging my code using Chrome Javascript console. But Chrome crashes at a certain point. I do not know ...
2
votes
2answers
454 views

Which is simpler for REST client call to return JSON - JQuery/JavaScript or Spring RestTemplate?

I've been trying to hack up an annotated Spring MVC web app (have some experience with Spring but also rusty and not a super programmer) but it's proving pretty hard to call a URL of my web app which ...
2
votes
1answer
246 views

Power of HTML5?

HTML5 is becoming more and more popular everyday. Many great online applications are now being created and described as pure HTML5 apps. (Like Muro) But I don't understand what is exactly so cool ...
35
votes
2answers
2k views

Are there any OO-principles that are practically applicable for Javascript?

Javascript is a prototype-based object oriented language but can become class-based in a variety of ways, either by: Writing the functions to be used as classes by yourself Use a nifty class system ...
0
votes
0answers
66 views

Best option to send image from javascript client to SQL server

From a client (browser), using javascript I want to send an image to sql server ( and store with user profile) (sql server), along with other data such as user id or name. Which option is better? ...
0
votes
1answer
110 views

JavaScript static methods retrieval

I have been thinking about it and wanted some feedback, recently I thought about doing it like this: function foo(){ if ( !foo.prototype.statics ){ foo.prototype.statics = { // ...
7
votes
3answers
535 views

Why there are no compound assignment operators for logical operators (such as ||, && etc)?

According to ECMA-262, part 11.13, following is the exhaustive list of compound assignment operators: *= /= %= += -= <<= >>= >>>= &= ^= |=. According to the part 11.11, var c ...
2
votes
2answers
201 views

Client side web development, general question

I'm a novice web developer, mostly worked with ASP.NET. On the server side, everything is very well documented and whenever there is an error, you get an explanatory error message. But on the client ...
0
votes
2answers
211 views

Is $.proxy a code smell?

I've been writing most of my javascript applications in an OO style close to what I would use for most other languages. However, this means that most callbacks need to have a reference to an object, ...
0
votes
1answer
55 views

Securing client side templates [closed]

I'm building a web application with backbone+mongo+node.js The current implementation uses mostly client side templating with backbone.js to render the pages. Since the templates have to be located ...
-1
votes
1answer
175 views

Is a web programmer supposed to know how to make anything a website may require? [duplicate]

I mean, maybe someone knows how to make a simpler ecommerce website, but doesn't know for example how to make a custom facebook like chat etc.. (or whole facebook for that matter). So, is a web ...
0
votes
2answers
105 views

Creating a text input simplifaction tool

I have been working on a project for several months now to write a web-based tool that will help me at work. I work at a call center and the CRM software that is used is wretched, we basically have to ...
7
votes
8answers
1k views

Rush to client-side in web development

In the past few months, I recognized a big excitement about client-side scripting in web development. But while server-side technologies are mature, stable and well accepted by backend-developers, ...
1
vote
1answer
133 views

Security in Authentication in single page apps

What's the most secure method of performing authentication in a single paged apps? I'm not talking about any specific client-side or server-side frameworks, but just general guidelines or best ...
9
votes
3answers
1k views

What functionality does WebStorm contain which RubyMine does not?

I am looking at buying Rubymine as I am doing a small amount of ruby, but a large amount of html5/javascript. I was going to get Webstorm as I do have a lot of pure html5/js based frameworks/apps ...
2
votes
1answer
366 views

What's the best way to use requestAnimationFrame and fixed frame rates

I recently got into using the HTML5-requestAnimationFrame-API a lot on animation-heavy websites, especially after seeing the Jank Busters talk. This seems to work pretty well and really improve ...
-2
votes
2answers
152 views

Is it reasonable to use Javascript MVC Frameworks for closed source paid web applications?

I am wondering if it is reasonable to write closed source, paid web apps in Javascript (JS MVC Frameworks like AngularJS, Backbone, Knockout, ...)? I'm concerned because in this type of frameworks you ...
1
vote
0answers
80 views

Expanding on vendor software?

I am a SCADA consultant and I work with many software packages. Due to their robust nature they include the capability of executing internal/external activex and vbscript code. Over the years I have ...
-1
votes
0answers
75 views

JavaScript on an IT industry website [closed]

I am a non-programmer and seek your advice. A friend provides IT staffing help to IT companies and is redoing his own website. The firm he hired is doing the home page in JavaScript. Will most IT ...
1
vote
2answers
117 views

Where's the separation between Presentation and Logic in Javascript MVC frameworks?

I had learned that following piece of code is bad because it is obstrusive javascript and mixes presentation with logic: <a href="" onclick="archive()">archive</a> The best practice was ...
29
votes
7answers
1k views

Design Patterns for Javascript [duplicate]

A lot of web frameworks have a MVC-style layout to code and approaching problems. What are some good similar paradigms for JavaScript? I'm already using a framework (jQuery) and unobtrusive js, but ...
3
votes
4answers
219 views

Function that modifies an argument, should I return the modified object?

We have a function that modifies a JS object, by adding some custom properties to it. The function doesn't return antyhing addTransaction: function (obj) { obj.transactionId = ...
5
votes
3answers
2k views

front end development test - html/css/jquery/javascript

We are continually revamping our front end developer test that we do in-house after a candidate has passed an online test. The online test has questions such as: How does a for loop start? What is ...
9
votes
2answers
281 views

How does Javascript code become asynchronous when using callbacks?

I've been doing a lot of reading online trying to figure out how to write asynchronous JavaScript code. One of the techniques that has come up a lot in my research is to use callbacks. While I ...
-2
votes
0answers
72 views

What is wrong with my Javascript Calculator? [closed]

I made a JavaScript calculator to calculate the price for counseling. I had it working in the old webpage and I'm converting to Drupal 7. Even though it worked before, I'm recieving an error now. ...
11
votes
1answer
270 views

Google Blink (new WebKit fork): Meaning of “Moving DOM into Javascript”?

From the Blink Blog: Finally we’d like to explore even larger ideas like moving the entire Document Object Model (DOM) into JavaScript. What does this mean? Does it mean WebKit's DOM is ...
1
vote
1answer
82 views

Finding the possible combinations of x switches out of y being true

I am working on an algorithm to find possible fills for gaps in text. My function will receive as input: (example) [false,"o",false,"b",false,"r"] representing the string "foobar" with some values ...
3
votes
1answer
109 views

Books/sources on inner workings of JavaScript [duplicate]

When I started studying C++ a couple of years ago, a lot of the books and texts I read did a very thorough job of explaining, how the code written would translate into concrete operations in the ...
0
votes
0answers
69 views

Strategy for reading and understanding Node.js code

Concretely I am looking at this 2000 line file of what I will pretty arbitrarily call "mediocre" code. It's not well-commented variable names and function names seem consistently intelligent ...
0
votes
0answers
6 views

Comparing two functions in JavaScript [migrated]

I'm developing a mobile app for my wife's 1st grade class so they can practice sight words. I'm a novice to JavaScript but I was able to pull off my first objective which was to take a JavaScript ...
2
votes
1answer
110 views

HG: fork web app project to separate API code from app code

I have a web app thats been in active development for about 8 months now and its becoming apparent that the project has a need to maintain a separation between app specific code and our OO Javascript ...
17
votes
4answers
7k views

Reasons NOT to use JSF [closed]

I am new to StackExchange, but I figured you would be able to help me. We're crating a new Java Enterprise application, replacing an legacy JSP solution. Due to many many changes, the UI and parts of ...
1
vote
2answers
236 views

Why does JavaScript count array lengths by the last index?

JavaScript seems to calculate the array length property by the number of the last index in the array rather than counting the number of items in the array. Example: var testArray = ['a', 'b', 'c']; ...
2
votes
1answer
120 views

How to dynamically add new posts once they are created

I am trying to design an application where users can make posts with Django on the backend. Right now I have to refresh the page with JavaScript every 20 or 30 seconds to check for new posts that ...
0
votes
1answer
187 views

What are the advantages of server-side Javascript and when would you use it? [duplicate]

I have been looking at server side Javascript technologies like, Rhino and Node.js. What are the advantages of using server-side Javascript and where in the server-side to they fit in a stack?
0
votes
1answer
63 views

In what way is JavaScript (ECMAScript) similar to Self and Scheme

When looking at the ECMAScript 4th Edition specification here it mentions that ES3 is a simple, highly dynamic, object-based language that takes its major ideas from the languages Self and ...

1 2 3 4 5 15
15 30 50 per page