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
"use strict"; | |
import React, { Component, ErrorInfo, ReactNode } from "react"; | |
interface ErrorBoundaryProps { | |
children: ReactNode; | |
} | |
interface ErrorBoundaryState { | |
hasError: boolean; | |
} |
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
/** | |
* Converts "exact (close variant)" search queries into negative keywords | |
* | |
* @author spencer@klientboost.com | |
* @version 1.0 | |
* | |
* -------------------------------- INSTRUCTIONS -------------------------------- | |
* | |
* 1. Download this script and upload it to your Google Ads account under | |
* Tools & Settings > Bulk Actions > Scripts |
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
// customQueryStringComponent.js | |
import React from "react" | |
import PropTypes from "prop-types" | |
import withLocation from "./withLocation" | |
const CustomQueryStringComponent = ({ search }) => { | |
const { custom } = search | |
return <p>Custom Value: {custom}</p> | |
} |
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
// withLocation.js | |
import React from 'react' | |
import { Location } from '@reach/router' | |
import queryString from 'query-string' | |
const withLocation = ComponentToWrap => props => ( | |
<Location> | |
{({ location, navigate }) => ( | |
<ComponentToWrap |
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
npm install @reach/router query-string |