Skip to content

Instantly share code, notes, and snippets.

View palcodes's full-sized avatar
📖
Learning

Aayush Pal palcodes

📖
Learning
View GitHub Profile
@cmod
cmod / hugofastsearch.md
Last active November 19, 2024 19:40 — forked from eddiewebb/readme.md
Fast, instant client side search for Hugo static site generator

Super fast, keyboard-optimized, client side Hugo search

This is a fork of and builds upon the work of Eddie Webb's search and Matthew Daly's search explorations.

It's built for the Hugo static site generator, but could be adopted to function with any json index compatible with Fuse fuzzy search library.

To see it in action, go to craigmod.com and press CMD-/ and start typing.

Fast Search

@AniketSK
AniketSK / Document.js
Created June 30, 2019 14:13
A higher order component to abstract away the connection to Firebase.
import React from 'react';
import firebase from 'firebase/app';
import { FormValidation } from '../../constants';
class Document extends React.Component {
constructor(props) {
super(props);
this.db = firebase.firestore();
this.db.settings({ timestampsInSnapshots: true });
this.willSubscribe = this.props.path != null;