CSS Perverts
Published in

CSS Perverts

How to write Premium JavaScript

Earn more for your work

Part I: Improving your code

Add ornate headers and comments

Reinvent the wheel, poorly.

var $ = document.querySelectorAll;

Use Roman Numerals

I = 1;
V = 5;
X = 10;
L = 50;
C = 100;
D = 500;
M = 1000;
for (var i = I; i<=X; i+=I) {
console.log('ad altiora tendo', i);
}

Functional Programming is IN

const five = 5;
const three = 3;
const eight = add(five, three);

Apply principles of typographic design

  • Make a bold statement by horizontally centering a single line of code and surrounding it with 40 carriage returns
  • Use non-Latin characters in variable names (D3.js does this)
  • Right justify sections of code
  • Insert comments in between arithmetic operations

Instead of descriptive comments, use vaguely appropriate passages from Dante’s Inferno

Block users who aren’t using an Apple device

Part II: Improving your personal brand

Insist on out of date methods of communication.

Keep ridiculous hours

Legally change your name to a single word.

Part III: The heartbreaking conclusion

--

--

The most important articles about code and technology you’ll ever read.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store