View Example.cs
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
private async Task DownloadSomething() | |
{ | |
using (var client = new WebClient()) | |
{ | |
var data = await client.DownloadDataTaskAsync(new Uri("https://www.google.pl")); | |
} | |
} |
View Example.cs
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
using (var client = new WebClient()) | |
{ | |
client.DownloadDataCompleted += Client_DownloadDataCompleted; | |
client.DownloadDataAsync(new Uri("https://www.google.pl")); | |
} | |
void Client_DownloadDataCompleted(object sender, DownloadDataCompletedEventArgs e) | |
{ | |
// Tutaj robimy coś z pobranymi danymi |
View Index.cshtml
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
<canvas id="myChart" width="200" height="200"></canvas> | |
<script> | |
var ctx = document.getElementById("myChart").getContext('2d'); | |
var myChart = new Chart(ctx, { | |
type: 'bar', | |
data: { | |
labels: ["Red", "Blue"], | |
datasets: [{ | |
label: 'Which color do you like?', | |
data: [12, 19], |
View Index.cshtml
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
<canvas id="myChart" width="200" height="200"></canvas> | |
<script> | |
var ctx = document.getElementById("myChart").getContext('2d'); | |
var myChart = new Chart(ctx, { | |
type: 'bar', | |
data: { | |
labels: ["Red", "Blue"], | |
datasets: [{ | |
label: 'Which color do you like?', |
View _Layout.cshtml
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
<!DOCTYPE html> | |
<html> | |
<head> | |
... | |
@Scripts.Render("https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.7.1/Chart.min.js") | |
</head> | |
<body> | |
... | |
</body> | |
</html> |
View build.cake
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
#tool nuget:?package=NUnit.Runners&version=2.6.4 | |
Task("tests") | |
.Does(() => | |
{ | |
NUnit("./TestsProjectFolder/bin/Release/TestsProject.dll"); | |
}); |
View build.cake
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
Task("build-android") | |
.IsDependentOn("restore") | |
.Does(() => | |
{ | |
MSBuild("./android_project_path.csproj", | |
c => c.SetConfiguration("Release") | |
.WithTarget("SignAndroidPackage") | |
); | |
}); |
View build.cake
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
Task("restore") | |
.Does(() => | |
{ | |
var nugetSettings = new NuGetRestoreSettings | |
{ | |
ArgumentCustomization = args => args.Append("-PackagesDirectory ./packages") | |
}; | |
NuGetRestore ("./project_path.csproj", nugetSettings); | |
}); |
View build.cake
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
Task("restore") | |
.Does(() => | |
{ | |
NuGetRestore ("./solution_path.sln"); | |
}); |
View build.cake
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
Task("clean") | |
.Does (() => | |
{ | |
CleanDirectories ("./**/bin"); | |
CleanDirectories ("./**/obj"); | |
}); |
NewerOlder