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
// In App.js in a new project | |
import React, {useEffect, useState} from 'react'; | |
import {View, Text, Button, TouchableOpacity} from 'react-native'; | |
import {NavigationContainer} from '@react-navigation/native'; | |
import {createStackNavigator} from '@react-navigation/stack'; | |
// import {enableScreens} from 'react-native-screens'; | |
// enableScreens(); | |
const computeResult = () => { | |
let result = 0; |
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
// See https://github.com/dialogflow/dialogflow-fulfillment-nodejs | |
// for Dialogflow fulfillment library docs, samples, and to report issues | |
'use strict'; | |
const functions = require('firebase-functions'); | |
const {WebhookClient} = require('dialogflow-fulfillment'); | |
const {Card, Suggestion} = require('dialogflow-fulfillment'); | |
process.env.DEBUG = 'dialogflow:debug'; // enables lib debugging statements | |
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
function currentlyOpen () { | |
var currentDateTime = new Date(); // current time | |
var hours = currentDateTime.getHours(); | |
var mins = currentDateTime.getMinutes(); | |
var day = currentDateTime.getDay(); | |
return day >= 1 && | |
day <= 5 && | |
hours >= 9 && | |
(hours < 17 || hours === 17 && mins <= 30); |
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
var request = require("request"); | |
var options = { | |
method: 'GET', | |
url: '{URL_HERE}', | |
}; | |
request(options, function (error, response, body) { | |
if (error) throw new Error(error); |
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
$(".download").each(function () { | |
url = ($(this).attr("href")); | |
var a = document.createElement('a'); | |
a.href = url; | |
a.download = "favicon.png"; | |
document.body.appendChild(a); | |
a.click(); | |
document.body.removeChild(a); | |
}) |
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
read -p "MySQL Password: " rootpassword | |
# Apache php mysql mysql-server installing | |
echo "Installing httpd" | |
yum install -y httpd | |
echo "Installing MYSQL" | |
yum install -y mariadb-server mariadb | |
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
// Top-level build file where you can add configuration options common to all sub-projects/modules. | |
buildscript { | |
repositories { | |
jcenter() | |
} | |
dependencies { | |
classpath 'com.android.tools.build:gradle:0.12.2' | |
// NOTE: Do not place your application dependencies here; they belong |