Skip to content

Instantly share code, notes, and snippets.

View smintz's full-sized avatar

Shahar Mintz smintz

  • Koh Phangan, Thailand
View GitHub Profile
@geuis
geuis / remote-typeahead.js
Created February 16, 2012 22:58
Remote data querying for Twitter Bootstrap 2.0 Typeahead without modifications
<script>
// Charles Lawrence - Feb 16, 2012. Free to use and modify. Please attribute back to @geuis if you find this useful
// Twitter Bootstrap Typeahead doesn't support remote data querying. This is an expected feature in the future. In the meantime, others have submitted patches to the core bootstrap component that allow it.
// The following will allow remote autocompletes *without* modifying any officially released core code.
// If others find ways to improve this, please share.
var autocomplete = $('#searchinput').typeahead()
.on('keyup', function(ev){
ev.stopPropagation();
@akhenakh
akhenakh / app.yaml
Last active March 4, 2023 19:22
Example of graceful shutdown with grpc healthserver * httpserver
readinessProbe:
exec:
command: ["/root/grpc_health_probe", "-addr=:6666"]
initialDelaySeconds: 1
livenessProbe:
exec:
command: ["/root/grpc_health_probe", "-addr=:6666"]
initialDelaySeconds: 2
imagePullPolicy: IfNotPresent
@barthap
barthap / Readme.md
Created October 28, 2020 10:03
Simple TypeScript GraphQL query builder

A simple GraphQL Query Builder experiment.

graphql folder structure

  • __tests__
  • queries - Domain specific Query API, e.g. UserQuery
  • mutations - Same as above, but mutations.
  • types - TypeScript interfaces directly corresponding to GQL schema types, e.g. User. Can be generated typedefs also
  • GraphqlClient.ts - GraphQL client + error handling. Can be any client, I use @urlq/core here.
  • QueryBuilder.ts - Query Builder implementation and some TypeScript magic