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
const usersApi = require("./users"); | |
module.exports = { | |
// /users | |
"post-users": usersApi.post, | |
"get-users": usersApi.get, | |
// /users/{userId} | |
"get-users-userId": usersApi.get, | |
"patch-users-userId": usersApi.patch, | |
"delete-users-userId": usersApi.delete, |
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
#!/bin/bash | |
# Get flutter | |
git clone https://github.com/flutter/flutter.git | |
FLUTTER=flutter/bin/flutter | |
# Configure flutter | |
FLUTTER_CHANNEL=master | |
FLUTTER_VERSION=v1.17.0 | |
$FLUTTER channel $FLUTTER_CHANNEL |
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
// When you just need to pass through the value yield from another generator function use: | |
yield* generatorFunction(); | |
// When you need to manipulate each yielded value | |
const generator = generatorFunction(); | |
let next = await generator.next(); | |
while (!next.done) { | |
let value = next.value; | |
// TODO apply any transformations to value here | |
yield value; |
OlderNewer