Skip to content

Instantly share code, notes, and snippets.

View develax's full-sized avatar
💭
∑☯

Joe develax

💭
∑☯
View GitHub Profile
@develax
develax / StepByStep.md
Last active October 26, 2018 14:19
Adding a new project to Git (on Windows) from scratch

Adding a new project to Git (on Windows) from scratch

Setup Git and commit the project files

  1. Go to https://git-scm.com download the installer and install it leaving everything by default (you can check that it was successful via windows console with the git --version command).
  2. Run windows console via cmd command and go to the project root folder (or run it from that folder).
  3. Execute the git init command (it will create the ".git" hidden folder inside your project folder).
  4. Run the git status command to check that nothing has been added to Git yet.
  5. To make some files (or folders) be tracked by Git run the git add filename.fileext command (you can run git status after to check whether the file has been added and ready to be commited).
  6. Add to the project root folder a new file called .gitignore. It should be a text file. Open it and write to it all files and folder (each one on a new line) you want to be ignored by Git. For example: node_modules/
  7. Add the .gitignore file
@develax
develax / JavaScript-Resources.md
Last active April 16, 2019 11:59
Educational Resources
@develax
develax / JsClassPrivateMembersExample.js
Last active October 28, 2018 14:13
Private properties and methods in JavaScript classes. Usually don't care about privacy so I use "pseudo privacy". But if do care (if there are some special requirements for that) I use something like in the example below.
class jobImpl{
// public
constructor(name){
this.name = name;
}
// public
do(time){
console.log(`${this.name} started at ${time}`);
this.prepare();
this.execute();
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<title>Function vs eval pefromance</title>
<script src="https://cdnjs.cloudflare.com/ajax/libs/benchmark/1.0.0/benchmark.min.js"></script>
<script src="./suite.js"></script>
</head>
<body>
<h1>Open the console to view the results</h1>
@develax
develax / T-SQL-Reminder.MD
Last active May 10, 2019 09:37
My T-SQL Reminder

T-SQL

The order of processing clauses

  • FROM
  • WHERE
  • GROUP BY
  • HAVING
  • SELECT
    • Expressions
  • DISTINCT
@develax
develax / EntityFrameworkCore.T-SQL.Notes.MD
Last active April 4, 2019 09:26
Entity Framework Core notes for T-SQL

Entity Framework Core for T-SQL notes

To SQL translations

Add + SaveChanges

db.Blogs.Add(new Blog { Url = $"http://blogs.msdn.com/adonet/{Guid.NewGuid()}" });
int count = db.SaveChanges();
@develax
develax / ASP.NET-Core+Vue.MD
Created April 20, 2019 09:59
ASP.NET Core + VueJS setup steps

ASP.NET Core + VueJS setup

Scaffolding a project with .NET CLI

  1. Install SPA templates:
> dotnet new --install Microsoft.AspNetCore.SpaTemplates::*

you will see