yarn test --maxWorkers=50% 2>&1 | grep FAIL | sort -u
yarn test --testTimeout=400 2>&1 | grep FAIL
Some of these tests may take some time as they have user interaction.
import React from "react"; | |
import { View, SafeAreaView, Text, Dimensions } from "react-native"; | |
import Animated, { | |
useSharedValue, | |
useAnimatedStyle, | |
useAnimatedScrollHandler, | |
interpolate, | |
interpolateColor, | |
Extrapolate, | |
} from "react-native-reanimated"; |
// TODO: make `pages` optional and measure the div when unspecified, this will | |
// allow more normal document flow and make it easier to do both mobile and | |
// desktop. | |
import { | |
createContext, | |
useCallback, | |
useContext, | |
useEffect, | |
useMemo, | |
useRef, |
Seven different types of CSS attribute selectors | |
// This attribute exists on the element | |
[value] | |
// This attribute has a specific value of cool | |
[value='cool'] | |
// This attribute value contains the word cool somewhere in it | |
[value*='cool'] |
use git diff to generate file list
git diff --name-only master
add ext filter
self.addEventListener('install', (e) => { | |
e.waitUntil( | |
caches.open("precache").then((cache) => cache.add("/broken.png")) | |
); | |
}); | |
function isImage(fetchRequest) { | |
return fetchRequest.method === "GET" && fetchRequest.destination === "image"; | |
} |
(function (context, trackingId, options) { | |
const history = context.history; | |
const doc = document; | |
const nav = navigator || {}; | |
const storage = localStorage; | |
const encode = encodeURIComponent; | |
const pushState = history.pushState; | |
const typeException = 'exception'; | |
const generateId = () => Math.random().toString(36); | |
const getId = () => { |
https://twitter.com/snookca/status/1073299331262889984?s=21
Happy to chat about this. There’s an obvious disclaimer that there’s a cost to css-in-js solutions, but that cost is paid specifically for the benefits it brings; as such it’s useful for some usecases, and not meant as a replacement for all workflows.
(These conversations always get heated on twitter, so please believe that I’m here to converse, not to convince. In return, I promise to listen to you too and change my opinions; I’ve had mad respect for you for years and would consider your feedback a gift. Also, some of the stuff I’m writing might seem obvious to you; I’m not trying to tell you if all people of some of the details, but it might be useful to someone else who bumps into this who doesn’t have context)
So the big deal about css-in-js (cij) is selectors.
EDIT: Well this has been linked now so just an FYI this is still TBD. Feel free to comment if you have suggestions for improvements. Also here is an unrolled Twitter thread of a lot of the tips I talk about on here.
I've been doing frontend for a while now and one thing that really gripes me is the interview. I think the breadth of knowledge of a "Frontend Engineer" has been so poorly defined that people really just expected you to know everything. Many companies have made this a hybrid role. The Web is massive and there are many MANY things to know. Some of these things are just facts that you learn and others are things you really have to understand.
Every time I interview, I go over the same stuff. I wanted to create a gist of the TL;DR things that would jog my memory and hopefully yours too.
Lots of these things are real things I've been asked that caught me off guard. It's nice to have something you ca
// This icon file is generated by build/generateIcons.ts | |
// tslint:disable | |
export { default as AccountBookFill } from '@ant-design/icons/lib/fill/AccountBookFill'; | |
export { default as AlertFill } from '@ant-design/icons/lib/fill/AlertFill'; | |
export { default as AlipayCircleFill } from '@ant-design/icons/lib/fill/AlipayCircleFill'; | |
export { default as AlipaySquareFill } from '@ant-design/icons/lib/fill/AlipaySquareFill'; | |
export { default as AliwangwangFill } from '@ant-design/icons/lib/fill/AliwangwangFill'; | |
export { default as AmazonCircleFill } from '@ant-design/icons/lib/fill/AmazonCircleFill'; | |
export { default as AmazonSquareFill } from '@ant-design/icons/lib/fill/AmazonSquareFill'; | |
export { default as ApiFill } from '@ant-design/icons/lib/fill/ApiFill'; |