Tag: CSS

Django & Webpack

Table Of Contents

  1. Overview
  2. Environment Setup & Requirements
  3. Setup Webpack
  4. First Webpack Packaged Assets


I’ll assume that you already know Django and is already well versed with it and you just want to integrate Webpack into your project. If you already know what is Webpack and how it works please proceed to Environment Setup & Requirements. For those of you that is not quite sure what Webpack will bring into your Django project then please read on for brief introductory of it. Continue reading

HTML And CSS: Padding HTML Element Without Resizing

For sometime now Ive been making my elements actual size subtracted by a certain percentage to compensate for the resizing triggered by padding and add a border that is the same color as the element to emulate a margin. This is really an ugly approach since depending on the device I might have over/under compensate the percentage but I found a css code that will make the padding grow inside the element size instead of growing its actual size. Below is the css code:

As you can see we have 3 different codes for different browser. With this when you use padding your html element will not auto re-size to accommodate the padding.

© 2018 James Baltar

Theme by Anders NorenUp ↑