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
import { Module } from '@nestjs/common'; | |
import { AppController } from './app.controller'; | |
import { AppService } from './app.service'; | |
import { UsersModule } from './users/users.module'; | |
import { TypeOrmModule } from '@nestjs/typeorm'; | |
import { typeOrmConfig } from './configs/db'; | |
import { IsUniqueConstraint } from './utils/validators'; | |
@Module({ | |
imports: [ |
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
AWS Amplify and AppSync with Expo (React Native) cheat sheet and reference guide | |
[AWS Amplify] https://aws-amplify.github.io | |
[Expo] https://expo.io | |
// In order to run the Android emulator with Expo you will need Android Studio with Android Virtual Device Manager | |
// In order to run the iOS simulator with Expo you'll need Xcode | |
INITIALIZE PROJECT |
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
# 1. Install brew --> http://brew.sh/ | |
# 2. run the following commands in your Terminal | |
brew tap homebrew/dupes | |
brew tap homebrew/versions | |
brew tap homebrew/homebrew-php | |
brew install --with-openssl curl | |
brew install --with-homebrew-curl --with-apache php71 | |
brew install php71-mcrypt php71-imagick | |
# 3. Follow these instructions to make Apache and php-cli use the newer php executable and make the change persist after reboot. | |
brew info php71 |
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
app.run(function ($rootScope, $location, AuthenticationModel) { | |
// Register listener to watch route changes. | |
$rootScope.$on('$routeChangeStart', function (event, next, current) { | |
if (!AuthenticationModel.isSignedIn() && next.requireAuthentication === true) { | |
$location.path('/signin'); | |
} | |
}); | |
}); |
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
<script src="http://maps.google.com/maps/api/js?sensor=false&libraries=geometry" type="text/javascript"></script> | |
<script type="text/javascript"> | |
function calcDistance (fromLat, fromLng, toLat, toLng) { | |
return google.maps.geometry.spherical.computeDistanceBetween( | |
new google.maps.LatLng(fromLat, fromLng), new google.maps.LatLng(toLat, toLng)); | |
} | |
</script> |
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
<!DOCTYPE html> | |
<meta charset=utf-8> | |
<meta name=viewport content="width=device-width, initial-scale=1, maximum-scale=1"> | |
<meta name=apple-mobile-web-app-capable content=yes> | |
<meta name=apple-mobile-web-app-status-bar-style content=black> | |
<title>Test fullscreen</title> | |
<style> | |
html, body { | |
margin: 0; | |
padding: 0; |