Skip to content

DougInAMug/dougwebb.site

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Purpose

  1. To provide a 'platform-independent', personal portal through which I can share:
  2. my works, including but not limited to: 1. slides, 1. articles, 1. posts, 1. event invitations.
  3. my rationale for the work I do,
  4. connection details,
  5. how I can support people/vice-versa.
  6. To learn and enjoy what's possible with modern web-design.

Design desires

  • mobile first
    • all other devices a close second
    • as in, check development with a phone. When happy, look at a larger screen.
  • simple
    • 'less is more'
    • 'it's perfect when nothing more can be taken away'
    • progressive disclosure
  • accessible
    • add alt-text to images
    • don't otherwise mess up screen-readers
    • big/clear enough navigation
    • allow phone-users to navigate without strain injuries
    • don't use prohibitive technologies (i.e. >90% web user browser support.)
  • no jumping
    • all content loaded in index.html, pages shown with checkbox hack/radio-buttons
    • placeholders for loading images
    • measures for desktop scrollbar width
    • consistent element placement
    • pre-fetching/loading/rendering if necessary

Local-serving for developing

install node http-server

$
npm install -g http-server

serve without caching

$
cd /path/to/baseDirectory
http-server -c-1 -p 8080

Nice CSS layout debugging

Using Dev Tools console

>>
$$('*').map((A,B)=>A.style.outline=`1px solid hsl(${B*B},99%,50%`)

Web-design resources

Inspiring websites

CSS notes

  • Use external stylesheets
    • Don't use inline styling
    • Don't use internal styling
  • Style using classes
    • Don't style tags ('elements')
    • Don't style IDs
    • Don't use !important
  • Mobile first
  • Be BEMy http://getbem.com/
    • Block independent entity .block
    • Element dependent entity .block__element
    • Modifier entity modifier .block--modifier
    • use modifier for external geometry (i.e. margin) to reuse blocks anywhere!
  • Margins collapse vertically
    • Borders and padding don't.
  • 'max-width' shrinks, 'width' adds scrollbar
  • "Percent is a measurement unit relative to the containing block."
  • Initial setting for display: flex;
    • flex-direction: row;
    • flex-wrap: nowrap;
    • justify-content: flex-start;
    • align-content: stretch;
  • http://learnlayout.com
  • http://paulcpederson.com/articles/css-for-people-who-hate-css/
  • "Classes for styles, tags for semantics, IDs for references." https://codeburst.io/how-to-write-css-when-you-hate-css-feb5a235b7f1
  • border-bottom: 0.1rem solid darkslategray; /* Possibly nicer way to style hyperlink underlines

CSS questions

  • can I use 'css-variables' natively with support? (e.g. navbar-height)
  • global selector: * vs html vs body