Less Web Development Cookbook
eBook - ePub

Less Web Development Cookbook

  1. 394 pages
  2. English
  3. ePUB (mobile friendly)
  4. Available on iOS & Android
eBook - ePub

Less Web Development Cookbook

Tools to learn more effectively

Saving Books

Saving Books

Keyword Search

Keyword Search

Annotating Text

Annotating Text

Listen to it instead

Listen to it instead

Less Web Development Cookbook


Table of Contents

Less Web Development Cookbook
Credits
Foreword
About the Author
About the Reviewers
www.PacktPub.com
Support files, eBooks, discount offers, and more
Why subscribe?
Free access for Packt account holders
Preface
What this book covers
What you need for this book
Who this book is for
Sections
Getting ready
How to do it…
How it works…
There's more…
See also
Conventions
Reader feedback
Customer support
Downloading the example code
Downloading the color images of this book
Errata
Piracy
Questions
1. Getting to Grips with the Basics of Less
Introduction
Downloading, installing, and integrating less.js
Getting ready
How to do it…
How it works…
There's more…
See also
Installing the lessc compiler with npm
Getting ready
How to do it…
How it works…
There's more…
See also
Using less.js with Rhino
Getting ready
How to do it…
How it works…
There's more…
Declaring variables with Less for commonly used values
Getting ready
How to do it…
How it works…
There's more…
See also
Setting the properties of CSS styles with mixins
Getting ready
How to do it…
How it works…
There's more…
Writing more intuitive code and making inheritance clear with nested rules
Getting ready
How to do it…
How it works…
There's more…
See also
Creating complex relationships between properties
Getting ready
How to do it…
How it works…
There's more…
See also
Using the built-in functions of Less
Getting ready
How to do it…
How it works…
There's more…
See also
Using namespaces to make your code reusable and portable
Getting ready
How to do it…
How it works…
2. Debugging and Documenting Your Less Code
Introduction
Debugging your code with less.js
Getting ready
How to do it…
How it works…
There's more…
See also
Using CSS source maps to debug your code
Getting ready
How to do it…
How it works…
There's more…
See also
Using Chrome Developer Tools to debug your code
Getting ready
How to do it…
How it works…
There's more…
See also
Commenting your code in Less
Getting ready
How to do it…
How it works…
There's more…
See also
Building style guides with tdcss.js
Getting ready
How to do it…
How it works…
See also
Building style guides with StyleDocco
Getting ready
How to do it…
How it works…
There's more…
See also
3. Using Variables and Mixins
Introduction
Deriving a set of variables from a single base variable
Getting ready
How to do it…
How it works…
See also
Value escaping with the ~"value" syntax
Getting ready
How to do it…
How it works…
There's more…
See also
Using variable interpolation
Getting ready
How to do it…
How it works…
There's more…
See also
Redeclaring variables based on lazy loading
Getting ready
How to do it…
How it works…
There's more…
See also
Using mixins to set properties
Getting ready
How to do it…
How it works…
There's more…
See also
Declaring a class and mixin at once
Getting ready
How to do it…
How it works…
There's more…
See also
Using selectors inside mixins
Getting ready
How to do it…
How it works…
There's more…
See also
Using parametric mixins
Getting ready
How to do it…
How it works…
There's more…
See also
4. Leveraging the Less Built-in Functions
Introduction
Converting units with the convert() function
Getting ready
How to do it…
How it works…
There's more…
See also
Using the default() function
Getting ready
How to do it…
How it works…
There's more…
See also
Embedding images with data URIs
Getting ready
How to do it
How it works…
There's more…
See also
Formatting strings
Getting ready
How to do it…
How it works…
There's more…
Replacing a text within a string
Getting ready
How to do it…
How it works…
There's more…
See also
Working with lists
Getting ready
How to do it…
How it works…
There's more…
Using mathematical functions
Getting ready
How to do it…
How it works…
There's more…
See also
Using the color() function
Getting ready
How to do it…
How it works…
There's more…
See also
Evaluating the type of a value
Getting ready
How to do it…
How it works…
There's more…
Creating color objects with RGB values
Getting ready
How to do it…
How it works…
There's more…
See also
Getting information about a color
Getting ready
How to do it…
How it works…
See also
Creating a color variant with the darken() and lighten() functions
Getting ready
How to do it…
How it works…
There's more…
Creating overlays of two colors with Less
Getting ready
How to do it…
How it works…
There's more…
See also
5. Extending and Referencing
Introduction
Referencing parent selectors with the & operator
Getting ready
How to do it…
How it works…
There's more…
See also
Referencing to the parent selector more than once
Getting ready
How to do it…
How it works…
There's more…
See also
Changing the selecting order with the & operator
Getting ready
How to do it…
How it works…
There's more…
See also
Using extend to merge selectors
Getting ready
How to do it…
How it works…
There's more…
Using extend in...

Table of contents

  1. Less Web Development Cookbook

Frequently asked questions

Yes, you can cancel anytime from the Subscription tab in your account settings on the Perlego website. Your subscription will stay active until the end of your current billing period. Learn how to cancel your subscription
No, books cannot be downloaded as external files, such as PDFs, for use outside of Perlego. However, you can download books within the Perlego app for offline reading on mobile or tablet. Learn how to download books offline
Perlego offers two plans: Essential and Complete
  • Essential is ideal for learners and professionals who enjoy exploring a wide range of subjects. Access the Essential Library with 800,000+ trusted titles and best-sellers across business, personal growth, and the humanities. Includes unlimited reading time and Standard Read Aloud voice.
  • Complete: Perfect for advanced learners and researchers needing full, unrestricted access. Unlock 1.4M+ books across hundreds of subjects, including academic and specialized titles. The Complete Plan also includes advanced features like Premium Read Aloud and Research Assistant.
Both plans are available with monthly, semester, or annual billing cycles.
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 990+ topics, we’ve got you covered! Learn about our mission
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more about Read Aloud
Yes! You can use the Perlego app on both iOS and Android devices to read anytime, anywhere — even offline. Perfect for commutes or when you’re on the go.
Please note we cannot support devices running on iOS 13 and Android 7 or earlier. Learn more about using the app
Yes, you can access Less Web Development Cookbook by Bass Jobsen, Amin Meyghani in PDF and/or ePUB format, as well as other popular books in Ciencia de la computación & Sistemas de gestión de contenidos. We have over one million books available in our catalogue for you to explore.