Could you try going to node_modules/jest-resolve/build/index.js
, and adding console.error(error)
before every line that says throw error?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type Response = { | |
contents: (Folder | Item)[]; | |
id: string; | |
name: string; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// a mapping of the numerals and their values | |
const NUMERALS = { | |
I: 1, | |
V: 5, | |
X: 10, | |
L: 50, | |
C: 100, | |
D: 500, | |
M: 1000 | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { useState, useEffect } from "react"; | |
/** | |
* A hook to syndicate and hydrate component state into local storage | |
* @param {string} storageKey - the key to store | |
* @param {*} [defaultVal] - an initial value for syndication | |
*/ | |
function useLocalStorage(storageKey, defaultVal = "") { | |
let initialVal = window.localStorage.getItem(storageKey); | |
if (initialVal) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#emailCaptureModal | |
.modal-body | |
.gform_wrapper | |
form | |
.gform_body | |
.email_input | |
.ginput_container_email | |
input::-webkit-input-placeholder, | |
#emailCaptureModal | |
.modal-body |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { ACTIONS } from './actions'; | |
const initialState = { | |
content: {}, | |
error: null, | |
isFetching: false, | |
lastFetched: 0 | |
} | |
const myContentReducer = (state = initialState, action = {}) => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { startFetch, abortFetch, errorFetch, updateFetch } from './syncActionCreators'; | |
// Run the async fetch if the data is stale, otherwise abort the fetch and log it | |
export const updateDemoContentAsync = () => { | |
// Redux Thunk allows this, see its docs for more detail | |
return (dispatch, getState) => { | |
// Get the state of the store synchronously for the REDUCER IN QUESTION, e.g. myContent here | |
const timeSinceLastFetch = getState().myContent.lastFetched; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { ACTIONS } from './actions'; | |
// Log if a fetch is aborted by the async call running too aggressively. | |
export const abortFetch = () => ({ | |
type: ACTIONS.abort | |
}); | |
/** | |
* Log an error if the async call fails | |
* @param {object} error - the error thrown. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const ACTIONS = { | |
abort: "abort", | |
error: "error", | |
start: "start", | |
update: "update" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const numMinutesToStale = 60; | |
export const timeToStale = numMinutesToStale * 60 * 1000; |
NewerOlder