Skip to content

Instantly share code, notes, and snippets.

QR qrobin

Block or report user

Report or block qrobin

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View drawing.js
import React, { Component } from 'react';
import { DrawingManager } from 'react-google-maps/lib/components/drawing/DrawingManager';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import { mapConfig } from '../../../../constants/component-configs';
import {
setShapeEventListener,
getShapeArea,
getFiltersFromGoogleMapsShape,
convertFromGoogleMapsShape
View map-tools.js
const polygonEvents = ['set_at', 'insert_at', 'remove_at'];
const circleEvents = ['center_changed', 'radius_changed'];
import turfCircle from '@turf/circle';
import { polygon as turfPolygon } from '@turf/helpers';
import { featureToWKT } from './map-utilities';
import { cond, has, hasIn, pipe, path } from 'ramda';
export const setShapeEventListener = (shape, action) => {
if (shape.radius) {
circleEvents.forEach(event => {
View Dot.js
import React from 'react';
import { View, StyleSheet } from 'react-native';
export const Dot = (props) => (
<View style={[ s.dot, (props.active && s.active) ]} />
);
const s = StyleSheet.create({
dot: {
width: 11,
View router.js
import React from 'react';
import { StackNavigator } from 'react-navigation';
import { Header, LeftButton, RightButton, Days } from 'atoms';
import { Loading } from 'wrappers';
import { goTo } from 'utils';
import {
// Loading
LoadingScreen,
View Main.js
import React, { Component } from 'react';
import { View, StyleSheet, ScrollView, Image, TouchableOpacity, Animated } from 'react-native';
import { Text } from 'atoms';
class Main extends Component {
constructor(props) {
super(props);
this.state = {
force: 0,
forceAction: false
View Router.js
import React from 'react';
import { View, Text } from 'react-native';
import { StackNavigator } from 'react-navigation';
/*
Level 1
*/
const Router = StackNavigator({
View poly.js
import React, { Component } from 'react';
import { withGoogleMap, GoogleMap } from 'react-google-maps';
import DrawingManager from 'react-google-maps/lib/drawing/DrawingManager';
// import { createContainer } from 'meteor/react-meteor-data';
import _ from 'underscore';
const DrawingGoogleMap = withGoogleMap(props => (
View MainApplication.java
package com.test;
import android.app.Application;
import com.facebook.react.ReactApplication;
import com.facebook.react.ReactNativeHost;
import com.facebook.react.ReactPackage;
import com.facebook.react.shell.MainReactPackage;
import com.facebook.soloader.SoLoader;
import com.test.testPackage.testPackage;
View App.js
class App extends Component {
constructor(props) {
super(props);
this.state = {
loggedIn: this.props.loggedIn
};
}
componentDidMount() {
// Here I have some logic with local database and the 'loggedIn' prop
View requirements.txt
amqp==1.4.9
anyjson==0.3.3
billiard==3.3.0.23
celery==3.1.23
Django==1.9
django-bootstrap3==7.0.1
django-celery==3.1.17
enum34==1.1.6
facebook-sdk==2.0.0
google-api-python-client==1.5.2
You can’t perform that action at this time.