This file contains hidden or 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 React from 'react'; | |
| import {StyleSheet, Text, View, Animated} from 'react-native'; | |
| import {API_KEY} from './utils/WeatherAPIKey'; | |
| import MyWeather from './components/Weather'; | |
| export default class App extends React.Component { | |
| state = { | |
| isLoading: false, | |
| temperature: 0, | |
| weatherCondition: null, |
This file contains hidden or 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
| const express = require('express'); | |
| const app = express(); | |
| const port = process.env.PORT || 4000; | |
| const bodyParser = require('body-parser'); | |
| const formidable = require('formidable'); | |
| app.use(bodyParser.json()); | |
| app.use( | |
| bodyParser.urlencoded({ | |
| extended: true, |
This file contains hidden or 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
| const express = require('express'); | |
| const app = express(); | |
| const port = 3000; | |
| const connection = require('./conf'); | |
| const bodyParser = require('body-parser'); | |
| // Support JSON-encoded bodies | |
| app.use(bodyParser.json()); | |
| // Support URL-encoded bodies | |
| app.use( |
This file contains hidden or 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
| const express = require('express'); | |
| const app = express(); | |
| const port = 3000; | |
| const connection = require('./conf'); | |
| const bodyParser = require('body-parser'); | |
| // Support JSON-encoded bodies | |
| app.use(bodyParser.json()); | |
| // Support URL-encoded bodies | |
| app.use( |
This file contains hidden or 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
| const express = require('express'); | |
| const app = express(); | |
| const port = 3000; | |
| const connection = require('./conf'); | |
| const bodyParser = require('body-parser'); | |
| // Support JSON-encoded bodies | |
| app.use(bodyParser.json()); | |
| // Support URL-encoded bodies | |
| app.use( |
This file contains hidden or 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
| const express = require('express'); | |
| const app = express(); | |
| const port = 3000; | |
| const connection = require('./conf'); | |
| app.get('/api/movies', (req, res) => { | |
| // connection to the database, and selection of employees | |
| connection.query('SELECT * FROM movie', (err, results) => { | |
| if (err) { | |
| // If an error has occurred, then the user is informed of the error |
This file contains hidden or 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
| const express = require('express'); | |
| const app = express(); | |
| const port = 3000; | |
| app.get('/', (req, res) => { | |
| res.send('Hello World'); | |
| }); | |
| app.get('/api/movies', (req, res) => { | |
| res.send('All films'); |
This file contains hidden or 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
| mysql> INSERT INTO school (name, country, capacity) | |
| -> VALUES | |
| -> ('Beauxbatons Academy of Magic', 'France', 550), | |
| -> ('Castelobruxo', 'Brazil', 380), | |
| -> ('Durmstrang Institute', 'Norway', 570), | |
| -> ('Hogwarts School of Witchcraft and Wizardry', 'United Kingdom', 450), | |
| -> ('Ilvermorny School of Witchcraft and Wizardry', 'USA', 300), | |
| -> ('Koldovstoretz', 'RUSSIA', 125), | |
| -> ('Mahoutokoro School of Magic', 'Japan', 800), | |
| -> ('Uagadou School of Magic', 'Uganda', 350); |
This file contains hidden or 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
| mysql> SELECT * | |
| -> FROM wizard | |
| -> WHERE birthday BETWEEN '1975-01-01' AND '1985-12-31'; | |
| +----+-----------+----------+------------+-------------+---------------------------------------+-----------+ | |
| | id | firstname | lastname | birthday | birth_place | biography | is_muggle | | |
| +----+-----------+----------+------------+-------------+---------------------------------------+-----------+ | |
| | 1 | harry | potter | 1980-07-31 | london | | 0 | | |
| | 2 | hermione | granger | 1979-09-19 | | Friend of Harry Potter | 0 | | |
| | 4 | ron | weasley | 1980-03-01 | | Best friend of Harry | 0 | | |
| | 5 | ginny | weasley | 1981-08-11 | | Sister of Ron and girlfriend of Harry | 0 | |
NewerOlder
