Skip to content

Instantly share code, notes, and snippets.

View rjuevesano's full-sized avatar

Richard Juevesano rjuevesano

View GitHub Profile
@rjuevesano
rjuevesano / loader.html
Last active September 17, 2018 08:09
An example of how to place the loader in the middle of the page.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Loader</title>
<style>
.loading {
z-index: 1;
@rjuevesano
rjuevesano / imageUploadFirebase.js
Last active April 21, 2018 09:15
Upload a base64 image with Firebase Storage
import { Platform } from 'react-native'
import ImagePicker from 'react-native-image-picker'
import RNFetchBlob from 'react-native-fetch-blob'
import firebase from 'firebase'
const Blob = RNFetchBlob.polyfill.Blob
const fs = RNFetchBlob.fs
window.XMLHttpRequest = RNFetchBlob.polyfill.XMLHttpRequest
window.Blob = Blob
package <PACKAGE_NAME>
import android.util.Log;
import com.baidu.mapapi.model.LatLng;
import com.baidu.mapapi.search.core.SearchResult;
import com.baidu.mapapi.search.geocode.GeoCodeResult;
import com.baidu.mapapi.search.geocode.GeoCoder;
import com.baidu.mapapi.search.geocode.OnGetGeoCoderResultListener;
import com.baidu.mapapi.search.geocode.ReverseGeoCodeOption;
package <PACKAGE_NAME>
import android.app.Activity;
import android.content.Context;
import com.facebook.react.ReactPackage;
import com.facebook.react.bridge.JavaScriptModule;
import com.facebook.react.bridge.NativeModule;
import com.facebook.react.bridge.ReactApplicationContext;
import com.facebook.react.uimanager.ViewManager;
@rjuevesano
rjuevesano / BaiduMapViewManager.java
Created March 23, 2018 02:25
Baidu map for android. Allows you to get current location, set mode, set zoom, set trafficEnabled, set heatMapEnabled and set marker.
package <PACKAGE_NAME>
import android.app.Activity;
import android.content.Context;
import android.util.Log;
import com.baidu.location.BDLocation;
import com.baidu.location.BDLocationListener;
import com.baidu.location.LocationClient;
import com.baidu.location.LocationClientOption;