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
function faireFondations(done) { | |
console.log("Fondation commencée"); | |
setTimeout(() => { | |
console.log("Fondation terminée"); | |
done(); | |
}, 2000); | |
} | |
function faireMurs(done) { | |
console.log("Mur commencé"); |
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
// Setup SQL | |
const connection = require("./conf"); | |
connection.connect(); | |
// Setup Express | |
const express = require("express"); | |
const app = express(); | |
const port = 3000; | |
// Setup body parser |
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
var express = require("express"); | |
var router = express.Router(); | |
/* GET home page. */ | |
router.get("/", function(req, res, next) { | |
res.render("index", { title: "Express" }); | |
}); | |
router.get( | |
"/superMiddleware", |
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
var express = require("express"); | |
var router = express.Router(); | |
/* GET home page. */ | |
router.get("/", function(req, res, next) { | |
res.render("index", { title: "Express" }); | |
}); | |
router.get( | |
"/superMiddleware", |
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
// Setup SQL | |
const connection = require("./conf"); | |
connection.connect(); | |
// Setup Express | |
const express = require("express"); | |
const app = express(); | |
const port = 3000; | |
// Setup body parser |
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
<!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>Quest local storage</title> | |
</head> | |
<body> | |
<label>First name</label> |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8" /> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge" /> | |
<title>Counter Redux</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1" /> | |
<!-- Redux CDN --> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/redux/4.0.1/redux.min.js"></script> |
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
-- Retourne le nom des équipes et le nombre de joueurs par équipe, le tout classé par nombre de joueurs par équipe, de la plus nombreuse à la moins nombreuse. | |
SELECT tea.name, COUNT(*) AS nb_players | |
FROM team AS tea | |
INNER JOIN player AS pla | |
ON tea.id = pla.team_id | |
GROUP BY tea.name | |
ORDER BY nb_players desc; | |
-- Retourne uniquement les noms des équipes complètes (ayant 14 joueurs ou plus, c’est-à- dire 7 joueurs et 7 remplaçants minimum), classés par ordre alphabétique. |
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
-- Retourne les noms, prénoms, rôle et équipe de tous les joueurs, classés dans l’ordre alphabétique par équipe, | |
-- puis par rôle dans l’équipe, puis par nom de famille, puis par prénom. | |
SELECT wiz.firstname, wiz.lastname, pla.role, tea.name AS team_name | |
FROM player AS pla | |
INNER JOIN wizard AS wiz | |
ON wiz.id = pla.wizard_id | |
INNER JOIN team AS tea | |
ON tea.id = pla.team_id | |
ORDER BY tea.name, pla.role, wiz.lastname, wiz.firstname; |
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
// Setup SQL | |
const connection = require("./conf"); | |
connection.connect(); | |
// Setup Express | |
const express = require("express"); | |
const app = express(); | |
const port = 3000; | |
// Setup body parser |
NewerOlder