25+ JavaScript Shorthand Coding Techniques

This really is a must read for any JavaScript developer. Michael Wanyoike, Sam Deering have written this guide to shorthand JavaScript coding techniques that they have picked up over the years. To help you understand what is going on, they have included the longhand versions to give some coding perspective.

This really is a must read for any JavaScript developer. Michael Wanyoike, Sam Deering have written this guide to shorthand JavaScript coding techniques that they have picked up over the years. To help you understand what is going on, they have included the longhand versions to give some coding perspective.

Continue reading “25+ JavaScript Shorthand Coding Techniques”

JS validacija, jednostavan način

Postoje 2 načina za validaciju formi na osnovu mesta izvršenja validacije. Jedna je obavezna server-side validacija (php, asp, java), a druga je na klijentskoj strani i za to se uglavnom koristi Java Script. Kažem uglavnom, jer moderni browser-i imaju ugrađene validatore. Continue reading “JS validacija, jednostavan način”

JavaScript Module Pattern

Smanjivanje broja globalnih promenljivih i njihovo premeštanje u lokalne (privatne) promenljive donosi više reda u svim jezicima, pa tako i u JavaScript kodu. Ako znamo da se na stranicama često nalazi više različitih skripti ovakvo označavanje ima više smisla.

Continue reading “JavaScript Module Pattern”