Skip to content

Instantly share code, notes, and snippets.

View Jezfx's full-sized avatar
✌️

jez Jezfx

✌️
View GitHub Profile
import { useState, useEffect, useCallback } from 'react'
function usePromise(createPromise) {
const [error, setError] = useState()
const [value, setValue] = useState()
useEffect(() => {
let current = true
createPromise().then(
{
"workbench.sideBar.location": "left",
"editor.minimap.enabled": false,
// "editor.detectIndentation": true,
"editor.tabSize": 2,
"todohighlight.isEnable": true,
"workbench.startupEditor": "newUntitledFile",
"workbench.colorTheme": "Framer Syntax",
"window.zoomLevel": 0,
"editor.renderControlCharacters": false,

Div with a attribute

  const Loader = styled.div<{ width: string }>`
  
  `;

Sets

@Jezfx
Jezfx / testing-framework.md
Last active November 20, 2019 07:02
testing framework WIP

Scripts

Developer Tests

  • Unit tests: yarn unit-test [-u]
  • Intergration tests: yarn int-test [-u]
  • Browser integration tests: cypress run

-u: flag to update snapshots.

@Jezfx
Jezfx / cv.md
Last active October 30, 2018 10:48
My CV 📔

Jez Williams

Freelace creative front end developer 🤓

Since graduating in computer science six years ago, I’ve found love in the creative side of the web. I’ve been freelancing for three years and enjoy being in new environments and learning new skills. Most recently, I’ve been building with React and progressing deeper into backend development to compliment my frontend skills.

💻 jezfx.com ✉️ jez@jezfx.com

Experience

Front end, React, Gatsby, GraphQL / Aug 2018 - present

@Jezfx
Jezfx / 001-styleguide.md
Last active August 23, 2018 20:12
A proposed style guide for while I was working at ao.com

Goals

Make everything opt-in

Start with a plain base and make any styling changes optional extras that can be added.

  • Ensure people can choose what they want.
  • Never force changes unless you really mean to. Provide additional functionality via options.
  • Expose API-like CSS.
  • It’s easier to opt into something than it is to undo it.

Single Responsibility Principle

@Jezfx
Jezfx / es6.md
Last active October 26, 2017 15:17
Learnings 📙 (es6, eslint)

ES6

Things I've learnt from Wesbos.com course

Scoping

var variables can be updated or mutated, which means you can re-delare a var again.

var variables are function scope. Which means their only available inside the function that they were created. Or, global scope if they've been created outside a function.

const and let are block scope which means they are confined inside any block, even if statements.

@Jezfx
Jezfx / resouces.md
Last active March 14, 2018 13:58
mentors and resources 👨‍💻 (js)
@Jezfx
Jezfx / libraries.md
Last active April 27, 2018 16:19
Collection of useful libraries