Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Getting Started with Ghost

You're reading from   Getting Started with Ghost Reach out to the world and publish great content with the power of Ghost

Arrow left icon
Product type Paperback
Published in Nov 2014
Last Updated in Feb 2025
Publisher
ISBN-13 9781783985180
Length 152 pages
Edition 1st Edition
Languages
Tools
Concepts
Arrow right icon
Authors (3):
Arrow left icon
 Bracey Bracey
Author Profile Icon Bracey
Bracey
 Balderston Balderston
Author Profile Icon Balderston
Balderston
Andrew J Boutte Andrew J Boutte
Author Profile Icon Andrew J Boutte
Andrew J Boutte
Arrow right icon
View More author details
Toc

Creating CSS via the Stylus preprocessor

Instead of manually typing out each line of CSS you're going to require for your Ghost theme, we're going to get you set up to become highly efficient in your development through use of the CSS preprocessor named Stylus.

Stylus can be described as a way of making CSS smart. It gives you the ability to define variables, create blocks of code that can be easily reused, perform mathematical calculations, and more. After Stylus code is written, it is compiled into a regular CSS file that is then linked into your design in the usual fashion.

It is an extremely powerful tool with many capabilities, so we won't go into them all here; however, we will cover some of the essential features that will feature heavily in our theme development process.

Variables

Stylus has the ability to create variables to hold any piece of information, from color codes to numerical values for use in your layout. For example, you could map out the color scheme of your...

lock icon The rest of the chapter is locked
Visually different images
CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Getting Started with Ghost
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
Modal Close icon
Modal Close icon