Pour le 21/10/2016 à 00h00.
Créer un nouveau groupe de routes REST (list, details, add, update, delete) pour un animal de votre choix.
L'animal doit avoir au minimum :
- un nom
- un slug
| { | |
| "env": { | |
| "browser": true, | |
| "jquery": true | |
| }, | |
| "rules": { | |
| "comma-dangle": [ 2, "never" ], | |
| "no-console": 1, | |
| "no-constant-condition": 2, | |
| "no-control-regex": 2, |
| { | |
| "env": { | |
| "node": true, | |
| "es6": true | |
| }, | |
| "ecmaFeatures": { | |
| "arrowFunctions": true, | |
| "blockBindings": true, | |
| "classes": true, | |
| "defaultParameters": true, |
| { | |
| "env": { | |
| "node": true | |
| }, | |
| "rules": { | |
| "comma-dangle": [ 2, "never" ], | |
| "no-console": 1, | |
| "no-constant-condition": 2, | |
| "no-control-regex": 2, | |
| "no-debugger": 1, |
| { | |
| "env": { | |
| "browser": true, | |
| "jquery": true | |
| }, | |
| "rules": { | |
| "comma-dangle": [ 2, "never" ], | |
| "no-console": 1, | |
| "no-constant-condition": 2, | |
| "no-control-regex": 2, |
I hereby claim:
To claim this, I am signing this object:
| fetch("/something") | |
| .then(JSON.parse) | |
| .then((_in) => (console.log(_in), _in)) | |
| .then(sendToClient); |
| let answer = DeepThought.getTheAnswer(); | |
| if (answer === 42) { | |
| // … do something with foo | |
| } |
| let answer; | |
| if ((answer = DeepThought.getTheAnswer()) === 42) { | |
| // … do something with foo | |
| } |
| const getReadableAddress = (address) => { | |
| if (address.street && address.number && address.zip) { | |
| return [ | |
| `${address.street} ${address.number}`, | |
| `${address.zip} ${address.city}`, | |
| address.country, | |
| ].join("\n"); | |
| } | |
| return `${address.city} (${address.country})`; |