Tag Info

Hot answers tagged

31

There is a third option ... write clean code via test driven development to implement the requirements that are needed today because YAGNI. The temptation to write code that isn't necessary at the moment but might be in the future suffers from several disadvantages ... from You ain't gonna need it: The time spent is taken from adding, testing or ...


25

Use a tool like Microsoft SketchFlow, or make your prototype in some other language or platform, making it nearly impossible to integrate into main development. There's also a joelonsoftware essay about showing screenshots and prototypes, where he makes unimplemented and unworked aspects appear obviously broken/unimplemented, making it clear where work ...


13

That's not how the prototype works. The prototype is used in the prototype chain. Whenever you try to get a property on an object it will check the object for that property name. If it does not exist it will look in the prototype. Example: var o = { "foo": "bar", "method": function() { ... } }; var o2 = Object.create(o); var o3 = Object.create(o); ...


12

Don't prototype with working code. Prototype with pencil and paper, or a software equivalent. Using Mockups feels like drawing, but because it’s digital, you can tweak and rearrange easily. Teams can come up with a design and iterate over it in real-time in the course of a meeting. Using paper has the benefit that team members can easily jump in, and ...


12

as usual... It Depends If you are prototyping to mitigate a risk or expose an unknown, just code it and expect to throw it away when you're done If you are prototyping for iterative refinement, just code it and expect to modify and refactor it frequently If you are starting to write the actual product but calling it prototyping so you can be lazy, then ...


12

Bubbling is an event flow mechanism in the DOM where events that are designated as "bubbling" (such as your click event), after being dispatched to their target, follow the target's parent chain upwards, checking for and triggering any event listeners registered on each successive target. In other words, given a DOM like this: <div id="foo"> ...


12

But it seems like they are avoided for the creation of executable applications and of bigger projects in general. Why that? I don't know, but the assumption is false. Larger projects use prototypical languages: JavaScript is the most popular language on github. Cloud9 is a full-blown cloud based IDE written in JavaScript that connects to GitHub. 98% ...


12

The "correct" answer is yes. TDD should be considered "best practice" wherever the tools for TDD are available either in the language or in the framework. Even if they aren't available in a form you may be used to with Java or .NET, you can create a simple program that consists of calling each of the unit test methods one at a time, catching thrown ...


12

The technical term for a class with a pure virtual function is abstract class, but that terms also applies if the class has additional non-pure virtual functions. Often the term Interface is used in C++ to describe an abstract class like Printable, that describes a service that can be provided by a range of different, otherwise unrelated classes. This ...


10

Stick to the Python. It has all the values, it just works and you already know it. If you're having doubts read this: http://www.scientificcomputing.com/High-Performance-Development-with-Python.aspx - very good article covering prototyping in python.


9

Classical inheritance inherits the behavior, without any state, from the parent class. It inherits the behavior at the moment the object is instantiated. Prototypal inheritance inherits behavior and state from the parent object. It inherits the behavior and state at the moment the object is called. When the parent object changes at run-time, the state and ...


8

I'm going to side with Paul Graham on this one: dynamic typing is most useful for creating programs organically, which is exactly what prototyping ought to be. The point is to get something done quickly that demonstrates the functionality of the final product, not the final product itself. Static typing is about formal correctness—well, ostensibly; at least ...


7

Personally I would worry about hiring someone who spent their time doing proof of concept stuff because it sounds like they are trained to get stuff working in a very beta/high level way but maybe couldn't deal with the real fiddly bits of actual implementation. That being said if the work was there it would be a wicked awesome job.


7

When you did fred.salary=20000 you have added the salary attribute only to fred. When using prototype, all employees you will create from then on will have the salary attribute. Say you have 100 instances of employees, and you wanted to add a salary attribute to all of them. You could to it manually, iterate over each employee and add it. Or you could use ...


7

Your own sequence and class diagrams probably do not depend that much on how the graphics engine behaves. During implementation, you will probably run into little quirks like 'I must call initFoo() before setupBar()' but those details most likely do not affect the design of your classes. Your tech-lead needs your design now, probably because other people ...


7

Gather better, more specific customer requirements. When you refine the requirements to the point where each requirement can be satisfied with a handful of classes, and you have a pretty good idea what those classes will look like in code, it will become much clearer how long things are going to take, and it will be much easier to declare success on each ...


6

If you are prototyping, why are you thinking about clean code? The very idea of prototyping is that it's meant to prove a concept or idea, and to be thrown away afterwards. I'm going to disagree with most everyone here by saying that if you are already thinking about the choice between writing clean code or getting something done quickly for prototyping, ...


6

Recent blog post about JS OO I believe what your comparing is classical OO emulation in JavaScript and classical OO and of course you can't see any difference. Disclaimer: replace all references to "prototypal OO" with "prototypal OO in JavaScript". I don't know the specifics of Self or any other implementation. However prototypal OO is different. With ...


6

First: Most of the time, you'll be using objects, not defining them, and using objects is the same under both paradigms. Second: Most prototypal environments use the same kind of division as class based environments -- mutable data on the instance, with methods inherited. So there's very little difference again. (See my answer to this stack overflow ...


6

The Guide to the Software Engineering Body of Knowledge describes prototyping as a method of requirements validation as well as requirements elicitation in Chapter 2, Section 6, Subsection 2: Prototyping is commonly a means for validating the software engineer's interpretation of the software requirements, as well as for eliciting new requirements. ...


6

How can be inherited an object? function inherit(o){ // inherit is called Object.create in modern implementations var F= function(){}; F.prototype=o; return new F(); } var parent = { name: "Josh", print: function(){ console.log("Hello, "+this.name); } }; parent.print(); // Hello, Josh var child = inherit(parent); ...


6

Isn't rapid prototyping (i.e. iterative and incremental development) sort of the whole point of Agile? It sounds like you're having issues with "perception is reality" at your organization. You might want to remind everyone that Agile doesn't mean "throw out all plans," any more than Test-Driven Development means "throw out all architecture." And Python ...


5

The Pencil Project is a Firefox addin that does nice and simple mockups. Pencil provides various built-in shapes collection for drawing different types of user interface ranging from desktop to mobile platforms. Starting from 2.0.2, Pencil is shipped with Android and iOS UI stencils pre-installed. This makes it even easier to start protyping apps with a ...


5

I use a combination of MS Paint and Visual Studio. I use VS to drag/drop all the controls I want onto a form, then screenshot it into MS paint to rearrange them until I like the way it looks. This way I can use simple, familiar, free, and always-accessible tools (for me) to mock up my UI, and the client can see the UI as it will probably look once the ...


5

If we're building a GUI application we almost ALWAYS create a prototype or POC (proof-of-concept). We'll establish what the visual vocabulary of the app will be. We usually get our client involved part way through the POC and make sure they understand what the purpose is and what they should be focusing on. I've never been sorry that I produced a ...


5

In the business world, it matters a-lot I too use to think that, until you hit the business world. Then its no longer simple enough to just take requirements and go forth and build. Its in business that user "flow" diagrams, and lo-fi prototypes really make sense. How the "program" operates is probably the easy part. In LOB (Line Of Business) apps, most ...


5

Never compromise the quality of your code. Writing junk code is a false economy. As other posters have suggested you can achieve this by using specific tools for mock ups. However, there are different reasons to building prototypes. Sometimes you can show what you need to without writing code, but often this is not the case. A stakeholder might want you ...


5

You can take a prototype to actual application pretty quickly if you choose the right tools. I recently prototyped an internal tool that will eventually replace an archaic collection of screens that manage internal data. The old system is not very intuitive and is extremely confusing for new hires. My stack: HTML5 Boiilerplate Blueprint CSS for Grids ...


5

If you're going to throw away the prototype and start over on the real app later, then I would suggest you use a tool like PowerPoint or Balsamiq or even paper. The low fidelity lets your users focus on the interaction and less on your colors or bubbly buttons. You actually get more kinks worked out faster with less investment like this. If you're aiming ...



Only top voted, non community-wiki answers of a minimum length are eligible