A compiled tweet of the CSS cheats sheet I created in the last few days

πŸ§΅πŸ‘‡
Border-radius
Flexbox
Relative and absolute positioning
Grid Layout
CSS box model
Alignment in flexbox
More amazing content is coming
stay aroundπŸ˜‰β€οΈ

β€’ β€’ β€’

Missing some Tweet in this thread? You can try to force a refresh
γ€€

Keep Current with Pratham πŸ‘¨β€πŸ’»πŸš€

Pratham πŸ‘¨β€πŸ’»πŸš€ Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @Prathkum

6 Feb
We can't create gradient border directly but we have a trickπŸ˜‰

A SHORT THREAD🧡 Image
This is pretty easy. It will just take 5 minutesπŸ˜„

STEP 1:
- Create your element around which you want to create gradient border

In this example I have a sqaure around which I'll create gradient border
STEP 2:
- Create pseudo-element with little extra height and width

Let's say if my sqaure height width is 300px then I'll set 304px height and width of pseudo-element
Read 6 tweets
4 Feb
Everything you need to know about useEffect hook of React

A beginner's guide

ThreadπŸ§΅πŸ‘‡
If you're familiar with class components then you might know that we have various lifecycle methods but in functional components, we don't have any lifecycle methods.

Instead we have a powerful hook called useEffectπŸ’ͺ
By using useEffect, you tell React that your component needs to do something after render. React will remember the function you passed (we'll refer to it as our β€œeffect”), and call it later after performing the DOM updates

So let's start by understanding the syntax firstπŸ‘‡
Read 14 tweets
2 Feb
Use the border radius effectively and create awesome shapes🀩

A Quick ThreadπŸ§΅πŸ‘‡ Image
You might have used something like this beforeπŸ‘‡

border-radius: 10px;
border-radius: 50%;
border-radius: 20px 10px;
border-radius: 10px 20px 30px 40px;

but have you used this?πŸ‘‡

border-radius: 40% 22% 33% 45% / 45% 69% 65% 36%;
Attached image showing a rectangle with 10px border-radius all sides. This is what we probably all know.

border-radius: 20px; Image
Read 9 tweets
31 Jan
Positioning in CSS allows you to display your element wherever you want on the screen

But when I was learning it, I found it little bit confusingπŸ˜…

So in this thread I'll try to explain it in easiest manner with practical implementation. Let's start

THREADπŸ§΅πŸ‘‡
There are 5 values that you can pass in position property

- static
- relative
- absolute
- fixed
- sticky

In this thread we will be focusing on relative and absolute positioning as both are widely used
Let's start with understanding what document flow is?

πŸ“Œ Elements are displayed on the screen as they written in the HTML document

Consider the following piece of code:

H1, P, H3 and div are displayed on the screen in exact order as they written in the HTML file.
Read 14 tweets
29 Jan
Everything you need to know about useState hook of React

A beginner's guide

ThreadπŸ§΅πŸ‘‡ Image
HeyπŸ‘‹

Hooks are powerful but confusing. Don't worry, I'll try to explain each hook in the easiest way in this thread series of React hooks

Let's start with useState, the most useful and simple hook in my opinion
Working with React hooks, first thing you need to do is to import the particular hook

It's quite easyπŸ‘‡

πŸ“Œ import { useState } from "react";
Read 14 tweets
27 Jan
Complete Beginner's guide to React in 2021βš›οΈ

A Long Thread🧡
If you just started or planning to getting started with React, this thread might help you.

In this thread I'll try to give you a quick overview to the world of React.

So if you find that sound interesting, prepare a coffee and give this thread a readπŸ˜‰
Before you go further into the React, make sure to check these things

βœ… Basic knowledge of HTML and CSS
βœ… JavaScript fundamentals and ES6 features

I would like to suggest you build a decent hold on JavaScript concepts because that is the backbone of React
Read 35 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!