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
Содержимое удалено по требованию правообладателя. |
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 userData = $jin.atom({ pull: function( ){ | |
setTimeout( function( ){ | |
userData.put({ name: 'User', time: Date.now() }) | |
}, 1000 ) | |
}}) | |
userData | |
.then( function( val ){ |
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
/** | |
* Инкапсуляция | |
* | |
* @class Greeter1 | |
*/ | |
var Greeter1 = function(){} | |
/** | |
* Генерирует прикольное имя | |
* |
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
import std.stdio; | |
import std.concurrency; | |
import std.conv; | |
import core.thread; | |
shared class Msg | |
{ | |
string value; | |
Msg next = null; | |
Tid from; |
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
import vibe.core.core; | |
import core.time; | |
import std.stdio; | |
int counter; | |
void say( string name ) { | |
for ( int i = 0 ; i < 3; i++ ) { | |
sleep( 100.msecs ); | |
writeln( ++counter , " " , name ); |
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
import std.stdio; | |
T eval( string op , T )( T a , T b ) { | |
return mixin( q{a} ~ op ~ q{b} ); | |
} | |
unittest { | |
writeln( eval!q{/}( 123 , 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
var args = {} | |
process.argv.slice(2).forEach( param => { | |
var values = param.split( '=' ) | |
var key = values.shift() | |
args[ key ] = ( args[ key ] || [] ).concat( values.join( '=' ) ) | |
} ) | |
var actions = { | |
'help help' : args => `help\t\tPrints help (default action)\n` , | |
'help' : args => `\nSuper-puper server!\n${ actions['actions']() }${ actions['options']() }`, |
Requirements:
- One line query through uri.
- Filtering
- Sorting
- Limitation
- Partial fetching
- Fetching linked resources
- Normalized response
- Bulk requests
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
type TestUserType = Assert< | |
typeof User.Value, | |
{ | |
readonly name: string | |
readonly birthday: Moment | |
readonly email: string & { Brand: "Email" } | undefined | |
} | |
> |
OlderNewer