Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Node.js High Performance

You're reading from   Node.js High Performance Take your application to the next level of high performance using the extensive capabilities of Node.js

Arrow left icon
Product type Paperback
Published in Aug 2015
Publisher
ISBN-13 9781785286148
Length 136 pages
Edition 1st Edition
Tools
Arrow right icon
Author (1):
Arrow left icon
Diogo Resende Diogo Resende
Author Profile Icon Diogo Resende
Diogo Resende
Arrow right icon
View More author details
Toc

Optimizations

Using patterns improves your application, as you use well-proven and well-tested concepts that help developers to better understand and eventually improve your code. But improving your code doesn't end here. There is another type of pattern that varies from language to language, and we call it optimization.

An optimization is a pattern that is not specific to any problem but specific to a code structure. The idea is to change the code to be more efficient or to use less memory or other types of resources while doing the same thing. The goal of an optimization is not to get simpler code or to make it more readable. It can be bigger but still readable. Don't optimize for the sake of optimizing and reducing your code readability.

As Node.js uses the V8 engine as the language processor, we have to use V8-specific optimizations in the code. Some optimizations work across versions, others not so much and the effort of optimizing might be worthless. This is because V8 is...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image